in

FedoraFedora

How to Install Node.js on Fedora 31 ?

An open source java script run time environment for Fedora

NODE.JS ON FEDORA

N

ode.js Fedora: It is an open-source javascript runtime environment. Node.js runs on various platforms (Windows, Linux, Unix, Mac OS X, etc.) and uses asynchronous programming. Node.js supports the server-side scripting so the developer can create dynamic web pages. Node.js files have the extension “.js” and Node.js uses JavaScript on the server. In this article, we will discuss the installation guidelines of Node.js Fedora 31 along with the features of Node.js.

Jump To:

  1. Installation guidelines to install Node.js on Fedora 31
  2. Instructions to Launch Node.js on Fedora 31
  3. Removal of Node.js on Fedora 31
  4. A Short Summary

Installation guidelines to install Node.js on Fedora 31:

  • Open the Terminal.
  • Add the node.js repository and built-in native addons on your system using the following commands.
$
sudo dnf install -y gcc-c++ make
Node.js repository
Node.js repository
$
curl -sL https://rpm.nodesource.com/setup_12.x | sudo -E bash -

Built-in Native Addon
Built-in Native Addon
  • After, Adding the node.js repository and built-in native addons you can install the node.js Application on your system.
  • To install Node.js make use of the installation Terminal command.
  • Open the Terminal.
  • Type the following Terminal command and execute it. Type your system password to confirm installation.
$
sudo dnf install nodejs
Node.js Installation
Node.js Installation

Instructions to Launch Node.js on Fedora 31

  • You can Launch Node.js using the Terminal Command. There is no GUI for Node.js
  • Open the Terminal.
  • Execute the below-mentioned command to launch Node.js.
$
node

Node.js Syntax:

Usage: node [options] [ script.js ] [arguments] node inspect [options] [ script.js | host:port ] [arguments]

Check this too  How to install the Shotcut App on Ubuntu 20.04 LTS?

Documentation can be found at https://nodejs.org/

Help Commands of Node.js:

Node.js Help options
Node.js Help options
.break    Sometimes you get stuck, this gets you out
.clear    Alias for .break
.editor   Enter editor mode
.exit     Exit the repl
.help     Print this help message
.load     Load JS from a file into the REPL session
.save     Save all evaluated commands in this REPL session to a file
Press ^C to abort current expression, ^D to exit the repl

For more help options Execute the following command on your Terminal.

$
node -h

Removal of Node.js on Fedora 31:

  • Open the Terminal.
  • Copy the following Terminal command and execute it. Type your system password to confirm Removal process.
$
sudo dnf remove nodejs
Removal of Node.js
Removal of Node.js

Features of Node.js:

  • Node.js can generate dynamic page content.
  • Node.js can create, open, read, write, delete, and close files on the server.
  • Node.js can add, delete, modify data in your database.
  • Node.js runs single-threaded, non-blocking, and very memory efficient.

Verdict:

This article demonstrates all the general rules to Install, Launch, and Remove Node.js no Fedora 31 and¬†explores the important help options to work on Node.js. I hope this article gives you more ideas while you work. In case of any queries regarding Node.js, please leave a reply and we will rectify your queries as soon. Stay connected you will get instant updates. Don’t forget to mention your valuable suggestions.

 

Leave a Reply

Your email address will not be published. Required fields are marked *

Wget Command

How to use Wget Command in Linux Ubuntu 19.10/18.04 LTS?

Ping command on Linux

How to use PING Command in Linux Ubuntu 19.10/18.04 LTS?