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

Not listening on 4000 #4

Open
ian opened this issue May 13, 2020 · 2 comments
Open

Not listening on 4000 #4

ian opened this issue May 13, 2020 · 2 comments

Comments

@ian
Copy link

ian commented May 13, 2020

This example appears to package and run but there is nothing listening on port 4000:

➜ npm run watch


> [email protected] watch /Users/ian/Projects/proxy
> webpack --mode production --watch

webpack is watching the files…

Hash: 899119836552fffb8086
Version: webpack 4.43.0
Time: 55ms
Built at: 05/12/2020 7:47:53 PM
  Asset      Size  Chunks             Chunk Names
main.js  1.16 KiB       0  [emitted]  main
Entrypoint main = main.js
[0] ./src/index.js 612 bytes {0} [built]

and then checking listening ports:

~ via ⬢ v12.13.1
➜ netstat -an | grep 4000

~ via ⬢ v12.13.1
➜
@gja
Copy link
Owner

gja commented May 13, 2020

hmmm. I actually think this is intended (though to be honest I can't remember why I did it this way).

npm start actually starts the server (and watches). npm watch just watches the compile, but doesn't actually serve anything. I'll update the readme or something to make this clear.

@ian
Copy link
Author

ian commented May 13, 2020

Ah. I think that was the confusion.

I really like how nextjs and other platforms have a npm start as a production server running against a build and npm run dev for local development / watch

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