-1
I am building the back-end of an application using Node.js and Typescript, I decided to create a script in package.json to facilitate the execution of the system
I inserted the following script:
"scripts": { "build": "tsc","dev:server": "ts-node-dev --inspect --transpileOnly --ignore node_modules src/server.ts" },
includes the flag --Inspect that enables vscode to connect to our Node code in the development environment, and flags --transpileOnly and --ignore node_modules to allow me a faster execution.
but when executing using the command yarn dev:server
I couldn’t solve it completely, I searched the network and found in https://www.npmjs.com/package/ts-node-dev the command: Yarn add ts-Node-dev --dev
Running this command can run the application but without the flags.
The right thing wouldn’t be
--inspect
instead of-inspect
? In the image it seems that you only used a hyphen.– Luiz Felipe