1

I want to integrate Eslint in my Nextjs application and prefer to run Eslint simultaneously with the development server. I have two scripts, namely server and lint and want to run them at the same time. I tried to implement it via dev script, but the development server seems not to be reloading on file changes in this implementation. Is there any way to run the two simultaneously?

 "scripts": {
    "dev": "npm run server && npm run lint",
    "server": "next -p 7777"
    "lint": "esw --fix components/**/*.js lib/**/*.js pages/**/*js"
  }
turisap
  • 231
  • 4
  • 13
  • Possible duplicate of [How can I run multiple npm scripts in parallel?](https://stackoverflow.com/questions/30950032/how-can-i-run-multiple-npm-scripts-in-parallel) – RobC May 02 '19 at 09:45
  • @RobC, I actually tried to run them as `npm run server && npm run lint`, but it didn't work as `nextjs` seemed to be not reloading on file changes. – turisap May 03 '19 at 05:27
  • Did you try using [concurrently](https://www.npmjs.com/package/concurrently) as suggested in the accepted [answer](https://stackoverflow.com/questions/30950032/how-can-i-run-multiple-npm-scripts-in-parallel#answer-30950298)? – RobC May 03 '19 at 08:00

0 Answers0