Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trouble running with with live-server #2

Open
thedixieflatline opened this issue Apr 4, 2019 · 1 comment
Open

Trouble running with with live-server #2

thedixieflatline opened this issue Apr 4, 2019 · 1 comment

Comments

@thedixieflatline
Copy link

npm live-server works and reports as running but in the browser either page not found or response error. I spent a bit of time trying to resolve but it was obviously something related to the location of the index.html etc. I tried all of the command line options but still no luck.

git clone
npm install
npm run build
npm start

So I swapped out live-server for webpack-dev-server (watch mode is by default) with following package.json config changes. New dependancy and new npm start command. This worked first time. Not sure if you have a local setup that is setup to run the way it is in the repo or you have something installed globally etc.
I just wanted to get it to run straight off a git clone without any local setup.

--package.json
{
"name": "Starfall",
"version": "0.1.0",
"description": "Starfall game (Phaser 3 + TypeScript)",
"main": "webpack.config.js",
"scripts": {
"build": "webpack",
"start": "webpack-dev-server --port 8085"
},
"author": "Mariya Davydova",
"license": "MIT",
"devDependencies": {
"webpack-dev-server": "^3.2.1",
"phaser": "^3.15.1",
"ts-loader": "^5.3.0",
"typescript": "^3.1.6",
"webpack": "^4.26.0",
"webpack-cli": "^3.1.2"
}
}

@gwilson2151
Copy link

I also had problems with live-server. I had to run it in a separate shell to get it working. I was going to switch to webpack-dev-server as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants