For development, you will only need Node.js and a node global package, express, body-parser, mongoose and MongoDB installed in your system.
-
Just go on official Node.js website and download the installer. Also, be sure to have
git
available in your PATH,npm
might need it (You can find git here). -
You can install nodejs and npm easily with apt install, just run the following commands.
$ sudo apt install nodejs $ sudo apt install npm
-
You can find more information about the installation on the official Node.js website and the official NPM website.
If the installation was successful, you should be able to run the following command.
$ node --version
v12.8.2
$ npm --version
6.14.5
all dependancies can be found in the package.json file of a respective task
$npm install <dependancy> --save
For task 4
mongod - The database server. mongos - Sharding router. mongo - The database shell (uses interactive javascript).
For command line options invoke:
$ ./mongod --help
To run a single server database:
$ sudo mkdir -p /data/db
$ ./mongod
$
$ # The mongo javascript shell connects to localhost and test database by default:
$ ./mongo
> help
.
https://docs.mongodb.com/manual/
$ git clone https://github.com/Aditya-06/Node.js-UNICODE
$ cd PROJECT_TITLE
$ node app.js
Run commmand $ node index.js and check out localhost:3000 on your web browser-- the ouput should be the following
Run command $ node app.js and check out localhost:3000 on your web browser-- the ouput should be the following