Skip to content

Commit 28a8136

Browse files
committed
fix: use to-string-loader to support shadow-dom css
1 parent 160eb61 commit 28a8136

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

webpack/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"webpack-dev-server": "^3.0.0",
77
"html-webpack-plugin": "^3.0.0",
88
// @if shadow-dom-open || shadow-dom-closed
9-
"raw-loader": "^3.0.0",
9+
"to-string-loader": "^1.0.0",
1010
// @endif
1111
"style-loader": "^1.0.0",
1212
"css-loader": "^3.0.0",

webpack/webpack.config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ module.exports = function(env/* @if jasmine || tape || mocha*/, { runTest }/* @e
6363
// @endif
6464
// @if shadow-dom-open || shadow-dom-closed
6565
{ test: /\.css$/i, issuer: /\.(js|ts)$/, use: [ "style-loader", cssLoader, postcssLoader ] },
66-
{ test: /\.css$/i, issuer: /\.html$/, use: [ cssLoader, postcssLoader ] },
66+
{ test: /\.css$/i, issuer: /\.html$/, use: [ "to-string-loader", cssLoader, postcssLoader ] },
6767
// @endif
6868
// @endif
6969
// @if less
@@ -72,7 +72,7 @@ module.exports = function(env/* @if jasmine || tape || mocha*/, { runTest }/* @e
7272
// @endif
7373
// @if shadow-dom-open || shadow-dom-closed
7474
{ test: /\.less$/i, issuer: /\.(js|ts)$/, use: [ "style-loader", cssLoader, postcssLoader, "less-loader" ] },
75-
{ test: /\.less$/i, issuer: /\.html$/, use: [ cssLoader, postcssLoader, "less-loader" ] },
75+
{ test: /\.less$/i, issuer: /\.html$/, use: [ "to-string-loader", cssLoader, postcssLoader, "less-loader" ] },
7676
// @endif
7777
// @endif
7878
// @if sass
@@ -81,7 +81,7 @@ module.exports = function(env/* @if jasmine || tape || mocha*/, { runTest }/* @e
8181
// @endif
8282
// @if shadow-dom-open || shadow-dom-closed
8383
{ test: /\.scss$/i, issuer: /\.(js|ts)$/, use: [ "style-loader", cssLoader, postcssLoader, { loader: "sass-loader", options: { sassOptions: { includePaths: ["node_modules"] } } } ] },
84-
{ test: /\.scss$/i, issuer: /\.html$/, use: [ cssLoader, postcssLoader, { loader: "sass-loader", options: { sassOptions: { includePaths: ["node_modules"] } } } ] },
84+
{ test: /\.scss$/i, issuer: /\.html$/, use: [ "to-string-loader", cssLoader, postcssLoader, { loader: "sass-loader", options: { sassOptions: { includePaths: ["node_modules"] } } } ] },
8585
// @endif
8686
// @endif
8787
// @if babel

0 commit comments

Comments
 (0)