-
Notifications
You must be signed in to change notification settings - Fork 12k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(@ngtools/webpack): do not remove outDir from the configuration
It would overwrite JavaScript files in the source directory. Even if its a virtual compiler host, this is still a BAD THING and TypeScript complains. Fixes angular/angular#21080 Might help with #8371 Fixes #8885
- Loading branch information
Showing
2 changed files
with
32 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import { ng } from '../../utils/process'; | ||
import { copyProjectAsset } from '../../utils/assets'; | ||
import { expectFileToMatch, writeMultipleFiles } from '../../utils/fs'; | ||
import { updateJsonFile } from '../../utils/project'; | ||
|
||
|
||
export default function () { | ||
return Promise.resolve() | ||
.then(() => writeMultipleFiles({ | ||
// Doesn't need to have content or be imported from anywhere. | ||
'src/some-javascript.js': '', | ||
})) | ||
.then(() => updateJsonFile('tsconfig.json', json => { | ||
json['compilerOptions']['allowJs'] = true; | ||
})) | ||
// We only test that the build passes. | ||
.then(() => ng('build')) | ||
} |