LoginSignup
5
4

More than 5 years have passed since last update.

node.jsで簡単にwebserverをたてる

Last updated at Posted at 2015-07-06

任意のディレクトリにpackage.jsonを作成

{
"name": "todos",
  "version": "1.0.0",
  "scripts": {
    "start": "http-server"
  },
  "dependencies": {
    "http-server": "^0.7.4"
  }
}

以下のコマンドを実行

npm install
npm start

起動したサーバーへアクセス

localhost:8080へ

5
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
4