Skip to content

Commit 29635a0

Browse files
committed
Update README.md to improve installation instructions
1 parent b8ce250 commit 29635a0

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,35 @@ default styling of HTML elements.
99
npm install --save @csstools/normalize.css
1010
```
1111

12+
### Usage in npm and webpack
13+
14+
Import [normalize.css] in CSS:
15+
16+
```css
17+
@import '~@csstools/normalize.css';
18+
```
19+
20+
Alternatively, import [normalize.css] in JS:
21+
22+
```js
23+
import '@csstools/normalize.css';
24+
```
25+
26+
In `webpack.config.js`, be sure to use the appropriate loaders:
27+
28+
```js
29+
module.exports = {
30+
module: {
31+
rules: [
32+
{
33+
test: /\.css$/,
34+
use: [ 'style-loader', 'css-loader' ]
35+
}
36+
]
37+
}
38+
}
39+
```
40+
1241
**Download**
1342

1443
See https://csstools.github.io/normalize.css/latest/normalize.css

0 commit comments

Comments
 (0)