Skip to content

Commit 883c022

Browse files
clydinhansl
authored andcommitted
feat(@angular/cli): support sourcemaps in injected stylesheets
1 parent 215b77d commit 883c022

File tree

4 files changed

+8
-10
lines changed

4 files changed

+8
-10
lines changed

package-lock.json

+5-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
"source-map": "^0.5.6",
8888
"source-map-loader": "^0.2.0",
8989
"source-map-support": "^0.4.1",
90-
"style-loader": "^0.13.1",
90+
"style-loader": "^0.19.1",
9191
"stylus": "^0.54.5",
9292
"stylus-loader": "^3.0.1",
9393
"tree-kill": "^1.0.0",

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

+1-4
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,7 @@ export function getStylesConfig(wco: WebpackConfigOptions) {
3636
const entryPoints: { [key: string]: string[] } = {};
3737
const globalStylePaths: string[] = [];
3838
const extraPlugins: any[] = [];
39-
// style-loader does not support sourcemaps without absolute publicPath, so it's
40-
// better to disable them when not extracting css
41-
// https://github.com/webpack-contrib/style-loader#recommended-configuration
42-
const cssSourceMap = buildOptions.extractCss && buildOptions.sourcemaps;
39+
const cssSourceMap = buildOptions.sourcemaps;
4340

4441
// Minify/optimize css in production.
4542
const minimizeCss = buildOptions.target === 'production';

packages/@angular/cli/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
"source-map-loader": "^0.2.0",
7373
"source-map-support": "^0.4.1",
7474
"istanbul-instrumenter-loader": "^2.0.0",
75-
"style-loader": "^0.13.1",
75+
"style-loader": "^0.19.1",
7676
"stylus": "^0.54.5",
7777
"stylus-loader": "^3.0.1",
7878
"uglifyjs-webpack-plugin": "~1.1.2",

0 commit comments

Comments
 (0)