From a5fdf841773605e38a5e23858d5f2efc9eb58ddc Mon Sep 17 00:00:00 2001 From: Martin V Date: Sun, 23 Apr 2017 15:34:06 +0200 Subject: [PATCH] docs(README): improve importLoaders section and example (#512) --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 081ad18a..d19bd58f 100644 --- a/README.md +++ b/README.md @@ -390,22 +390,22 @@ import { className } from 'file.css'; ### `importLoaders` -The query parameter `importLoaders` allow to configure which loaders should be applied to `@import`ed resources. - -`importLoaders`: That many loaders after the css-loader are used to import resources. +The query parameter `importLoaders` allows to configure how many loaders before `css-loader` should be applied to `@import`ed resources. **webpack.config.js** ```js { test: /\.css$/, use: [ + 'style-loader', { loader: 'css-loader', options: { - importLoaders: 1 + importLoaders: 1 // 0 => no loaders (default); 1 => postcss-loader; 2 => postcss-loader, sass-loader } }, - 'postcss-loader' + 'postcss-loader', + 'sass-loader' ] } ```