Skip to content

Commit

Permalink
feat: add debugging configs
Browse files Browse the repository at this point in the history
  • Loading branch information
asadkhalid305 committed May 30, 2024
1 parent 1a3b7b0 commit 0aae7db
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 0 deletions.
42 changes: 42 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Express.js: debug server-side",
"type": "pwa-node",
"request": "launch",
"runtimeExecutable": "pnpm",
"runtimeArgs": ["run", "start:debug"],
"skipFiles": ["<node_internals>/**"],
"console": "integratedTerminal",
"cwd": "${workspaceFolder}/apps/api",
"restart": true,
"internalConsoleOptions": "neverOpen",
"program": "${workspaceFolder}/apps/api/src/index.ts"
},
{
"name": "Next.js: debug server-side",
"type": "node-terminal",
"request": "launch",
"command": "pnpm run dev",
"cwd": "${workspaceFolder}/apps/client"
},
{
"name": "Next.js: debug client-side",
"type": "chrome",
"request": "launch",
"url": "http://localhost:3000"
},
{
"name": "Next.js: debug full stack",
"type": "node-terminal",
"request": "launch",
"command": "pnpm run dev",
"serverReadyAction": {
"pattern": "- Local:.+(https?://.+)",
"uriFormat": "%s",
"action": "debugWithChrome"
}
}
]
}
3 changes: 3 additions & 0 deletions apps/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
"name": "api",
"version": "0.0.0",
"private": true,
"type": "module",
"scripts": {
"start": "node dist/index.js",
"start:debug": "node --loader ts-node/esm src/index.ts",
"dev": "tsup --watch --onSuccess \"node dist/index.js\"",
"build": "tsup",
"clean": "rm -rf dist",
Expand Down Expand Up @@ -35,6 +37,7 @@
"@types/supertest": "^6.0.2",
"jest": "^29.7.0",
"supertest": "^6.3.4",
"ts-node": "^10.9.2",
"tsup": "^8.0.2",
"typescript": "^5.3.3"
}
Expand Down

0 comments on commit 0aae7db

Please sign in to comment.