To install Node.js, you can navigate to Node.js Homepage, select option and download.
For MacOS user, you can also use Homebrew to download Node:
brew install node.
To check the current version of Node.js, we can use the command:
npm is a Node package manager, and is installed when you install Node.js.
To check the current version of npm, we can use the command:
I recommend installing
nodemon, a useful that automatically restarts the node application when file changes in the directory are detected.
In this example we save nodemon as devDependencies.
npm i -D nodemon
Check nodemon version:
To install MongoDB, go to https://www.mongodb.com/download-center and choose your version according to the OS.
If you use MacOS, you can install MongoDB by Homebrew.
Once you have Homebrew installed, you’ll need to tap the MongoDB formula repository by running the following command in your terminal:
brew tap mongodb/brew
Next, run this command to install MongoDB:
brew install firstname.lastname@example.org
To start running Mongo, use this command:
brew services start mongodb
To check the version of MongoDB, run:
I recommend using Visual Studio Code for editior. VS Code will give you a solid editor with customization and a lot of useful functionality.
To download VS Code (highly recommended), simply go to its website at https://code.visualstudio.com.