Skip to content

Commit 99cf4ce

Browse files
committed
feat(@ngtools/webpack): add JIT support to AngularCompilerPlugin
1 parent 24241a7 commit 99cf4ce

File tree

16 files changed

+478
-139
lines changed

16 files changed

+478
-139
lines changed

packages/@angular/cli/models/webpack-configs/typescript.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ function _createAotPlugin(wco: WebpackConfigOptions, options: any) {
8080
exclude: []
8181
}, options);
8282

83-
if (wco.buildOptions.experimentalAngularCompiler && !options.skipCodeGeneration) {
83+
if (wco.buildOptions.experimentalAngularCompiler) {
8484
return new AngularCompilerPlugin(pluginOptions);
8585
} else {
8686
return new AotPlugin(pluginOptions);

packages/@angular/cli/tasks/eject.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ class JsonWebpackSerializer {
122122
const basePath = path.dirname(tsConfigPath);
123123
return Object.assign({}, value.options, {
124124
tsConfigPath,
125-
mainPath: path.relative(value.basePath, value.options.mainPath),
125+
mainPath: path.relative(basePath, value.options.mainPath),
126126
hostReplacementPaths: Object.keys(value.options.hostReplacementPaths)
127127
.reduce((acc: any, key: string) => {
128128
const replacementPath = value.options.hostReplacementPaths[key];
@@ -132,7 +132,7 @@ class JsonWebpackSerializer {
132132
}, {}),
133133
exclude: Array.isArray(value.options.exclude)
134134
? value.options.exclude.map((p: any) => {
135-
return p.startsWith('/') ? path.relative(value.basePath, p) : p;
135+
return p.startsWith('/') ? path.relative(basePath, p) : p;
136136
})
137137
: value.options.exclude
138138
});

0 commit comments

Comments
 (0)