Skip to content

Commit b5dfb85

Browse files
committed
Update the README to reflect file extension changes
1 parent 520b22a commit b5dfb85

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

README.md

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,16 @@ npm install --save-dev codebandits/react-app-rewire-css-modules sass-loader node
2020

2121
## Usage
2222

23+
Use the following file extensions for any CSS Modules styles:
24+
25+
- `*.module.css`
26+
- `*.module.sass`
27+
- `*.module.scss`
28+
29+
Files with just a `*.css` file extension will load normally, without the CSS Modules loader.
30+
31+
### Example
32+
2333
In your react-app-rewired configuration:
2434

2535
```javascript
@@ -38,7 +48,7 @@ module.exports = function override(config, env) {
3848
In your React application:
3949

4050
```scss
41-
// src/App.scss
51+
// src/App.module.scss
4252

4353
.app {
4454
color: aqua;
@@ -53,7 +63,7 @@ In your React application:
5363
// src/App.js
5464

5565
import React from 'react';
56-
import styles from './App.scss';
66+
import styles from './App.module.scss';
5767

5868
export default ({text}) => (
5969
<div className={styles.app}>{text}</div>

0 commit comments

Comments
 (0)