-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathtsconfig.json
More file actions
21 lines (21 loc) · 876 Bytes
/
tsconfig.json
File metadata and controls
21 lines (21 loc) · 876 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
/**
* This configuration will allow us to generate TypeScript declaration (.d.ts) files without porting the entire project to TypeScript
* Reference: https://www.typescriptlang.org/docs/handbook/declaration-files/dts-from-js.html
**/
{
"include": ["src/**/*"],
"compilerOptions": {
// Tells TypeScript to read JS files instead of ignoring them as source files
"allowJs": true,
// Generate d.ts files
"declaration": true,
// This compiler run should only output d.ts files
"emitDeclarationOnly": true,
// Explicitly set rootDir to src to output types directly to outDir without src/ nesting
"rootDir": "src",
// Types should go into this directory, otherwise the .d.ts files would be placed next to the javascript files
"outDir": "types",
// Go to the js file when using IDE functions like "Go to Definition" in VSCode"
"declarationMap": true
}
}