1) Use the 5.0.4 CLI to generate a simple application. I chose to not use any databases to make it as simple as possible.
2) Use the generator (npx feathers generate service) to create a basic custom service. I didn't add TypeBox nor any schema to make it as simple as possible.
3) Using VSCode, set a breakpoint in the custom service class file in the Find method and create a launch.json file with VSCode.
Expected behavior
Should be able to set a breakpoint and debug the application
Actual behavior
Debugger crashes with this error:
C:\Program Files\nodejs\node.exe .\src\index.ts
Process exited with code 1
(node:27216) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.
(Use `node --trace-warnings ...` to show where the warning was created)
System configuration
Tell us about the applicable parts of your setup.
tsconfig.json needs "sourceMap": true added to it. Would be nice if the setting was in the template used by the generator. Here is my tsconfig (from the generator) with sourceMaps added. This allows me to debug the application.
Steps to reproduce
1) Use the 5.0.4 CLI to generate a simple application. I chose to not use any databases to make it as simple as possible. 2) Use the generator (npx feathers generate service) to create a basic custom service. I didn't add TypeBox nor any schema to make it as simple as possible. 3) Using VSCode, set a breakpoint in the custom service class file in the Find method and create a launch.json file with VSCode.
Expected behavior
Should be able to set a breakpoint and debug the application
Actual behavior
Debugger crashes with this error:
System configuration
Tell us about the applicable parts of your setup.
tsconfig.json needs "sourceMap": true added to it. Would be nice if the setting was in the template used by the generator. Here is my tsconfig (from the generator) with sourceMaps added. This allows me to debug the application.
NodeJS version: Node 18.16.0; npm 9.6.4; pnpm 8.2.0
Operating System: Windows 11 x64
VSCode: -Version: 1.77.3 (user setup) -Commit: 704ed70d4fd1c6bd6342c436f1ede30d1cff4710 -Date: 2023-04-12T09:16:02.548Z -Electron: 19.1.11 -Chromium: 102.0.5005.196 -Node.js: 16.14.2 -V8: 10.2.154.26-electron.0 -OS: Windows_NT x64 10.0.22621 -Sandboxed: Yes