Node.js console-based application
Make a file called console.js with the following code.
console.log('Hello this is the console-based application');
console.log('This all will be printed in console');
// The above two lines will be printed in the console.
To run this file, open the node.js command prompt and go to the folder where the console.js file exists and write the following command. It will display content on console. The console.log() method of the console class prints the message passed in the method in the console.
Node.js Basics
Node.js is a powerful runtime environment that allows developers to build server-side applications using JavaScript. In this comprehensive guide, we’ll learn all the fundamental concepts of Node.js, its architecture, and examples.
Table of Content
- What is Node.js?
- Key features of Node.js
- Setting Up Node.js
- Core Modules
- Datatypes in Node.js
- Node.js console-based application
- Node.js web-based application
- Common Use Cases
- Conclusion