Skip to content

Commit cb7f23e

Browse files
committed
Merge pull request #759 from GabiGrin/add-defaults-to-tsconfig
explicitly add compile on save and build on save on generated tsconfig
2 parents 54ad038 + f663889 commit cb7f23e

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

dist/main/tsconfig/tsconfig.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,8 @@ function createProjectRootSync(srcFile, defaultOptions) {
284284
var projectSpec = {};
285285
projectSpec.compilerOptions = tsToRawCompilerOptions(defaultOptions || exports.defaults);
286286
projectSpec.filesGlob = defaultFilesGlob;
287+
projectSpec.compileOnSave = true;
288+
projectSpec.buildOnSave = false;
287289
fs.writeFileSync(projectFilePath, prettyJSON(projectSpec));
288290
return getProjectSync(srcFile);
289291
}

lib/main/tsconfig/tsconfig.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -495,6 +495,8 @@ export function createProjectRootSync(srcFile: string, defaultOptions?: ts.Compi
495495
var projectSpec: TypeScriptProjectRawSpecification = {};
496496
projectSpec.compilerOptions = tsToRawCompilerOptions(defaultOptions || defaults);
497497
projectSpec.filesGlob = defaultFilesGlob;
498+
projectSpec.compileOnSave = true;
499+
projectSpec.buildOnSave = false;
498500

499501
fs.writeFileSync(projectFilePath, prettyJSON(projectSpec));
500502
return getProjectSync(srcFile);

0 commit comments

Comments
 (0)