1.0.2 • Published 4 years ago
http-server-node v1.0.2
http-server-node
Simple, Based on NodeJs, command-line http server
![]()
http-server-node: on NodeJs based, command-line http server
http-server-node is a http server. It is not for Production usage only for test or learning purpose
Installation:
Globally via npm
npm install --global http-server-nodeThis will install http-server-node globally so that it may be run from the command line anywhere.
Running on-demand:
Using npx you can run the script without installing it first:
npx http-server-node
As a dependency in your npm package:
npm install http-server-nodeUsage:
http-server-node [entryPoint][entryPoint] defaults to index.html
Now you can visit http://localhost:3030 to view your server
Available Options:
| Command | Description | Defaults |
|---|---|---|
-p or --port | Port to use.. | 3030 |
-o or --open | Open browser window after starting the server. | false |
-h or --host | Host to use | 127.0.0.1 |
-e or --entryPoint | Entry Point to use | index.html |
Magic Files
index.htmlwill be served as the default file to any directory requests.