From 3f30f0c680d3043343b7d26a786e5ff22c2fb685 Mon Sep 17 00:00:00 2001 From: Arunoda Susiripala Date: Mon, 24 Oct 2016 18:58:27 +0530 Subject: [PATCH] Allow to use postcss for CSS @imports. (#564) Based on https://github.com/facebookincubator/create-react-app/pull/929 --- dist/server/build.js | 0 dist/server/config/defaults/webpack.config.js | 2 +- src/server/config/defaults/webpack.config.js | 2 +- 3 files changed, 2 insertions(+), 2 deletions(-) mode change 100755 => 100644 dist/server/build.js diff --git a/dist/server/build.js b/dist/server/build.js old mode 100755 new mode 100644 diff --git a/dist/server/config/defaults/webpack.config.js b/dist/server/config/defaults/webpack.config.js index 3c533be04a22..15c35db9450a 100644 --- a/dist/server/config/defaults/webpack.config.js +++ b/dist/server/config/defaults/webpack.config.js @@ -22,7 +22,7 @@ module.exports = function (storybookBaseConfig) { newConfig.module.loaders = [].concat((0, _toConsumableArray3.default)(storybookBaseConfig.module.loaders), [{ test: /\.css?$/, include: _utils.includePaths, - loaders: [require.resolve('style-loader'), require.resolve('css-loader'), require.resolve('postcss-loader')] + loaders: [require.resolve('style-loader'), require.resolve('css-loader') + '?importLoaders=1', require.resolve('postcss-loader')] }, { test: /\.json$/, include: _utils.includePaths, diff --git a/src/server/config/defaults/webpack.config.js b/src/server/config/defaults/webpack.config.js index da960652925e..9d226d24999c 100644 --- a/src/server/config/defaults/webpack.config.js +++ b/src/server/config/defaults/webpack.config.js @@ -11,7 +11,7 @@ module.exports = (storybookBaseConfig) => { include: includePaths, loaders: [ require.resolve('style-loader'), - require.resolve('css-loader'), + `${require.resolve('css-loader')}?importLoaders=1`, require.resolve('postcss-loader'), ], },