You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+8-8
Original file line number
Diff line number
Diff line change
@@ -50,7 +50,7 @@ module.exports = {
50
50
51
51
### `toString`
52
52
53
-
You can also use the css-loader results directly as string, such as in Angular's component style.
53
+
You can also use the css-loader results directly as a string, such as in Angular's component style.
54
54
55
55
**webpack.config.js**
56
56
```js
@@ -137,7 +137,7 @@ The syntax `:local(.className)` can be used to declare `className` in the local
137
137
138
138
With `:local` (without brackets) local mode can be switched on for this selector. `:global(.className)` can be used to declare an explicit global selector. With `:global` (without brackets) global mode can be switched on for this selector.
139
139
140
-
The loader replaces local selectors with unique identifiers. The choosen unique identifiers are exported by the module.
140
+
The loader replaces local selectors with unique identifiers. The chosen unique identifiers are exported by the module.
141
141
142
142
```css
143
143
:local(.className) { background: red; }
@@ -162,7 +162,7 @@ exports.locals = {
162
162
}
163
163
```
164
164
165
-
CamelCase is recommended for local selectors. They are easier to use in the within the imported JS module.
165
+
CamelCase is recommended for local selectors. They are easier to use within the imported JS module.
166
166
167
167
`url()` URLs in block scoped (`:local .abc`) rules behave like requests in modules.
168
168
@@ -280,9 +280,9 @@ You can also specify the absolute path to your custom `getLocalIdent` function t
280
280
281
281
To include source maps set the `sourceMap` option.
282
282
283
-
I.e. the extract-text-webpack-plugin can handle them.
283
+
I.e. the extract-text-webpack-plugin can handle them.
284
284
285
-
They are not enabled by default because they expose a runtime overhead and increase in bundle size (JS source maps do not). In addition to that relative paths are buggy and you need to use an absolute public path which include the server URL.
285
+
They are not enabled by default because they expose a runtime overhead and increase in bundle size (JS source maps do not). In addition to that relative paths are buggy and you need to use an absolute public path which includes the server URL.
286
286
287
287
**webpack.config.js**
288
288
```js
@@ -327,7 +327,7 @@ import { className } from 'file.css';
327
327
328
328
### `importLoaders`
329
329
330
-
The query parameter `importLoaders` allows to configure how many loaders before `css-loader` should be applied to `@import`ed resources.
330
+
The query parameter `importLoaders` allows you to configure how many loaders before `css-loader` should be applied to `@import`ed resources.
331
331
332
332
**webpack.config.js**
333
333
```js
@@ -347,7 +347,7 @@ The query parameter `importLoaders` allows to configure how many loaders before
347
347
}
348
348
```
349
349
350
-
This may change in the future, when the module system (i. e. webpack) supports loader matching by origin.
350
+
This may change in the future when the module system (i. e. webpack) supports loader matching by origin.
351
351
352
352
<h2align="center">Examples</h2>
353
353
@@ -378,7 +378,7 @@ module.exports = {
378
378
379
379
### Extract
380
380
381
-
For production builds it's recommended to extract the CSS from your bundle being able to use parallel loading of CSS/JS resources later on.
381
+
For production builds it's recommended to extract the CSS from your bundle being able to use parallel loading of CSS/JS resources later on.
382
382
This can be achieved by using the [mini-css-extract-plugin](https://github.com/webpack-contrib/mini-css-extract-plugin) to extract the CSS when running in production mode.
0 commit comments