-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathreadme.txt
More file actions
64 lines (53 loc) · 1.72 KB
/
Copy pathreadme.txt
File metadata and controls
64 lines (53 loc) · 1.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
Install tsc & typescript
npm intall -g tsc
npm install -g typescript
************* Setting up VS Code ********************************
Build Task
1) Press ctrl + shift + B in VS Code that prompts for configure task runner
2) Click configure now -> configure Typescript using tsconfig
3) Sample looks below
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "0.1.0",
"command": "tsc",
"isShellCommand": true,
"args": ["--target","ES2015",
"--sourceMap",
"--outDir", "JS",
"--module", "commonJS",
"TeamIndia.ts"],
"showOutput": "silent",
"problemMatcher": "$tsc"
}
4) The args command above controls the JS File emitted
Debug task
1)Click debug icon in VS
2)Click Launch icon at the top that creates launch.json in the workspace
3)Configure the file to be debugged
Sample looks below to debug a file named TeamIndia.js
{
// Use IntelliSense to learn about possible Node.js debug attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Launch Program",
"program": "${workspaceRoot}\\TeamIndia.ts",
"cwd": "${workspaceRoot}",
"outFiles": ["${workspaceRoot}\\JS\\*.js"],
"sourceMaps": true
},
{
"type": "node",
"request": "attach",
"name": "Attach to Process",
"port": 5858,
"outFiles": [],
"sourceMaps": true
}
]
}