Questions tagged [nodemon]

nodemon is an automated process that monitors the directory for a given node application. When files change in this directory, nodemon automatically restarts the node application.

nodemon is an automated process that monitors the directory for a given node application. When files change in this directory, nodemon automatically restarts the node application.

Basic usage

nodemon [your node app]
nodemon ./server.js localhost 8080
1355 questions
56
votes
5 answers

nodemon + express, listen port =?

I create a simple node project using express: npm install -g express-generator express test cd test/ && npm install PORT=3000 npm start So this gets the test app up and running on port 3000. Great. Now I'd like to use nodemon to run this project.…
tivoni
  • 1,990
  • 4
  • 19
  • 37
53
votes
9 answers

Forever + Nodemon running together

Is there any way to have both of this packages running together? So basically I want to have best from both worlds. Running server automatically (and restarting when there is an error) and also automatic updates when there is .js file change…
Patrik Fuhrmann
  • 969
  • 1
  • 12
  • 21
52
votes
16 answers

Can Visual Studio Code be configured to launch with nodemon

I have installed nodemon as a global package in my system. It works when I executed nodemon in cmd. But when I am using vscode with this launch.json file, vscode throws this exception: request launch: runtime executable XXX\XXX\XXX\XXX\nodemon…
Mickel Sierra
  • 705
  • 1
  • 5
  • 11
51
votes
9 answers

How to debug a nodemon project in VSCode

I have a NodeJs project and I run it using nodemon, I wish to run it in debug mode for development tasks, but I am unable to do so. I found that I'll need to add the right configuration to the launch.json file under .vscode folder, I have a app.js…
Dev1ce
  • 5,390
  • 17
  • 90
  • 150
48
votes
10 answers

Webpack --watch and launching nodemon?

Thanks to an excellent answer by @McMath I now have webpack compiling both my client and my server. I'm now on to trying to make webpack --watch be useful. Ideally I'd like to have it spawn something like nodemon for my server process when that…
XeroxDucati
  • 5,130
  • 2
  • 37
  • 66
47
votes
4 answers

expressGraphQL is not a function

I am learning GraphQL for my project using this tutorial: https://www.youtube.com/watch?v=ZQL7tL2S0oQ&ab_channel=WebDevSimplified and I get the error: TypeError: expressGraphQL is not a function at Object. I have already tried: this…
Swantewit
  • 966
  • 1
  • 7
  • 19
46
votes
6 answers

Typescript paths not working in an Express project

I am trying to use TypeScript's paths functionality so that I don't need to use relative imports any more. Here is my tsconfig.json file: { "compilerOptions": { "target": "es5", "module": "commonjs", "strict": true, …
Sriram R
  • 2,109
  • 3
  • 23
  • 40
44
votes
6 answers

Nodemon inspect/debug not working?

Running nodemon --inspect index.js or nodemon --debug index.js doesn't work. Node Version : 8.9.1 Nodemon Version : 1.12.6 I have tried these with no luck : nodemon --inspect-brk index.js nodemon -- --inspect index.js nodemon index.js --…
Pramesh Bajracharya
  • 2,153
  • 3
  • 28
  • 54
42
votes
31 answers

Nodemon: Error: listen EADDRINUSE: address already in use :::5000

I'm creating a project and using nodejs, express for the backend. Everything works fine but as I make any change in the file, nodemon is unable to restart the server due to following error: Error: listen EADDRINUSE: address already in use…
Rishav Pandey
  • 664
  • 1
  • 6
  • 18
38
votes
8 answers

What is difference between node and nodemon?

in my package.json I am using "scripts": { "start": "node app.js" }, but if I use nodemon replace with node app.js like "scripts": { "start": "nodemon app.js" }, then what will happen? Because when I got any error at server side, other API…
Alex
  • 818
  • 1
  • 8
  • 17
37
votes
7 answers

Why does the node inspector not start when I am using nodemon and ts-node?

I have a simple node server written in typescript. My package.json is configured as: "scripts": { "build": "tsc", "dev": "nodemon --watch src/**/* -e ts,json --exec ts-node ./src/server.ts", "debug": "nodemon --verbose --watch src/**/* -e…
user60456
37
votes
6 answers

Nodemon not restarting when html file is modified

I'm learning Node.js, my demo has two files: /server.js /public/index.html /server.js will get /public/index.html and then return to the client. I'd like to use nodemon to auto reload when /public/index.html is modified. However, it seems like…
Hom nom nom nom ...
  • 479
  • 1
  • 5
  • 14
36
votes
5 answers

Nodemon Doesn't Restart in Windows Docker Environment

My goal is to set up a Docker container that automatically restarts a NodeJS server when file changes are detected from the host machine. I have chosen nodemon to watch the files for changes. On Linux and Mac environments, nodemon and docker are…
RyanNHG
  • 1,009
  • 2
  • 8
  • 20
36
votes
20 answers

nodemon not working properly

I am running my nodejs app by npm start I just installed nodemon by sudo npm install -g nodemon so that i can get my server restarted when i save changes to files. But when i try to start the server, something like this nodemon ./app.js localhost…
bruceparker
  • 1,235
  • 1
  • 17
  • 33
34
votes
12 answers

NodeJS - nodemon not restarting my server

I installed NodeJS (4.4.5) and then proceed to install nodemon (1.9.2) as well, I follow all the instrucctions of instalation (npm install -g nodemon) I created a new folder, inside I have my server.js with some basic code: var http =…
BrianCas
  • 749
  • 3
  • 12
  • 22
1
2
3
90 91