fix(@angular/cli): use JIT by default with ng5

Fix #8259
This commit is contained in:
Filipe Silva 2017-10-31 21:11:58 +00:00 committed by Hans
parent 99e1b5ac5c
commit 453ff5ceb3
2 changed files with 3 additions and 3 deletions

View File

@ -95,7 +95,7 @@ export class NgCliWebpackConfig<T extends BuildOptions = BuildOptions> {
sourcemaps: true,
extractCss: false,
namedChunks: true,
aot: AngularCompilerPlugin.isSupported(),
aot: false,
buildOptimizer: false
},
production: {

View File

@ -14,9 +14,9 @@ export default function () {
// These tests should be moved to the default when we use ng5 in new projects.
return Promise.resolve()
// tests for register_locale_data transformer
.then(() => ng('build', '--locale=fr'))
.then(() => ng('build', '--aot', '--locale=fr'))
.then(() => expectFileToMatch('dist/main.bundle.js', /registerLocaleData/))
.then(() => expectFileToMatch('dist/main.bundle.js', /angular_common_locales_fr/))
.then(() => rimraf('dist'))
.then(() => expectToFail(() => ng('build', '--locale=no-locale')))
.then(() => expectToFail(() => ng('build', '--aot', '--locale=no-locale')))
}