diff --git a/.vscode/launch.json b/.vscode/launch.json index e1acee5270f195..54492d339f4cb8 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -209,9 +209,7 @@ "args": ["build"], "cwd": "${workspaceRoot}/packages/fluentui/react-northstar", "env": { - "NODE_ENV": "development", - // This is used in scripts/babel/index.js to enable sourcemaps - "DEBUG": "1" + "NODE_ENV": "development" }, "sourceMaps": true, "console": "integratedTerminal" diff --git a/scripts/ts-node-register.js b/scripts/ts-node-register.js index 0e07abb27540e2..dfd85e1013b25e 100644 --- a/scripts/ts-node-register.js +++ b/scripts/ts-node-register.js @@ -1,7 +1,6 @@ const tsNode = require('ts-node'); -const jju = require('jju'); -const fs = require('fs'); const path = require('path'); +const { readConfig } = require('./read-config'); // Until ts-node re-enables caching, we're using version 7 (before caching was disabled). // https://github.com/TypeStrong/ts-node/issues/951 @@ -12,6 +11,9 @@ tsNode.register({ // // Register ts-node so that it uses the scripts directory's tsconfig // dir: __dirname, // Hack to work around lack of `dir` option: manually pass in tsconfig - compilerOptions: jju.parse(fs.readFileSync(path.join(__dirname, 'tsconfig.json'))).compilerOptions, + compilerOptions: { + ...readConfig(path.join(__dirname, 'typescript/tsconfig.common.json')).compilerOptions, + ...readConfig(path.join(__dirname, 'tsconfig.json')).compilerOptions, + }, skipProject: true, // don't read tsconfig within ts-node });