Debug ts files with ts-node and visual code

Add the next configuration on the launch.json of visual code

{
            "name": "Current TS File",
            "type": "node",
            "request": "launch",
            "args": ["${relativeFile}"],
            "runtimeArgs": ["--nolazy", "-r", "ts-node/register"],
            "sourceMaps": true,
            "cwd": "${workspaceRoot}",
            "protocol": "inspector",
        }

Thanks to this site.

Sean felices! :) Y siéntanse libres de opinar ;)

No hay comentarios:

Publicar un comentario