Skip to content
This repository has been archived by the owner on Jul 19, 2021. It is now read-only.

Commit

Permalink
Fix cssVarLoader running on development build
Browse files Browse the repository at this point in the history
  • Loading branch information
t-kelly committed Oct 16, 2018
1 parent 698dc65 commit 71cc131
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
3 changes: 1 addition & 2 deletions packages/slate-tools/tools/webpack/config/parts/css.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ const postcssLoader = {
const cssVarLoader = {loader: '@shopify/slate-cssvar-loader'};

cssRule.use = [
isDev ? styleLoader : MiniCssExtractPlugin.loader,
cssVarLoader,
...(isDev ? [styleLoader] : [MiniCssExtractPlugin.loader, cssVarLoader]),
cssLoader,
postcssLoader,
];
Expand Down
5 changes: 3 additions & 2 deletions packages/slate-tools/tools/webpack/config/parts/sass.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,14 @@ const sassLoader = {
};

sassRule.use = [
isDev ? styleLoader : MiniCssExtractPlugin.loader,
cssVarLoader,
...(isDev ? [styleLoader] : [MiniCssExtractPlugin.loader, cssVarLoader]),
cssLoader,
postcssLoader,
sassLoader,
];

debugger;

part.module.rules.push(sassRule);

module.exports = part;

0 comments on commit 71cc131

Please sign in to comment.