Today it’s really easy to setup Node.js and install npm apps on Windows systems. Here’s a guide how to setup a HTTP server.

Nodejs

  • First you must install NodeJS.
  • Open the Node.js command prompt to run following commands.
  • Run this command to install a HTTP server: npm install http-server -g
npm install http-server -g 
Nodejs
npm install http-server windows screenshot

Install mongodb library for Node

npm install mongodb 
  • And start the HTTP server: http-server /path/to/docroot with a path to the folder you want to share. Your folder must have some files before it works.
cd C:UsersusernameAppDataRoamingnpmnode_moduleshttp-server
Nodejs
http-server root acces/starting screenshot 
C:UsersusernameAppDataRoamingnpmnode_moduleshttp-server start
  • Now just open http://localhost:8080/ in your browser.
SHARE
Previous articleHow to run AngularJS Project
Next articleNokia X Developer Tools Installing and configuring

Abdullah Al Mahamud is a programmer and founder of Thedevline an Inspiration blog since 2014. live in Bangladesh. He is passionate about Technology and Design. He works on the freelancing marketplace as a freelancer and has also written for Useful Article in this blog

Leave a Reply

avatar
  Subscribe  
Notify of