MustansirZia / next-express-bootstrap-boilerplate

:zap: JavaScript boilerplate for a full stack app built using React.js, Next.js, Express.js, react-bootstrap, SCSS and full SSR with eslint.
MIT License
112 stars 20 forks source link

Could not run nodemon #9

Open ShintaroNippon opened 5 years ago

ShintaroNippon commented 5 years ago

I'm facing this issue

next-express-bootstrap-boilerplate@0.1.1 dev /home/shintaro/Desktop/projects/github/frontend nodemon app.js

[nodemon] 1.19.0 [nodemon] reading config ./nodemon.json [nodemon] to restart at any time, enter rs [nodemon] or send SIGHUP to 20111 to restart [nodemon] ignoring: ./node_modules//* ./.next/*/ ./app//* [nodemon] watching: app.js [nodemon] watching extensions: js,json [nodemon] starting node app.js [nodemon] forking [nodemon] child pid: 20124 [nodemon] watching 1 file Compiling ...

but when I made localhost:3000 - my port

it doesn't loads

I have updated nodemon and created thid nodemon .json

{ "verbose": true, "ignore": ["node_modules", ".next","app/"], "watch": ["app.js"], "ext": "js json" }

in package.json I have this

"dev": "nodemon -w app.js app.js"

Could you help me please...

Thanks Carlos Vieira

MustansirZia commented 5 years ago

Hi @ShintaroNippon! There's already a script bundled for nodemon in this boilerplate. Any specific reason why you're using your own? For now, just try "dev": "nodemon --ignore app/ app.js" and then npm run dev or yarn dev. Also, I think to start the dev server you must be able to access the internet, can it? This is something Next.js does in order to check for updates. Could be one of the reasons why your server isn't starting and isn't attaching to port.

ShintaroNippon commented 5 years ago

Thanks by the reply, I have define a port to production... let me check that. many thanks. Carlos Vieira

MustansirZia commented 5 years ago

Alright then. You can define the port anyway without further configuring nodemon.