Hello World with Node.js
Jan 7, 2021
Prerequisites:
Check out the previous post to come on track with us!
To implement your 1st node.js project, open the terminal in the project directory, and initialize your nodejs project with the following command:
npm init
The prompt will ask for some information, just press enter till you exit the setup process
Now create a file named helloWorld.js in the project directory and type the following line of code:
console.log(“Hello World!”);
Save the code and in the command prompt type:
node helloWorld.js