Skip to content

Commit

Permalink
build: improve CSS Modules experience (#27)
Browse files Browse the repository at this point in the history
  • Loading branch information
pure-js authored Oct 29, 2023
1 parent 6bef0b7 commit 03047f3
Show file tree
Hide file tree
Showing 7 changed files with 373 additions and 33 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,18 @@ It correctly bundles React in production mode and optimizes the build for the be
The build is minified and the filenames include the hashes.\
Your app is ready to be deployed!

## CSS naming convention

<!-- prettier-ignore -->
```css
/*-- For CSS Modules --*/

.beautiful_input {} /* Block */
.beautiful_input.ivalid_txt {} /* Element */
.beautiful_input.m_invalid {} /* Modificator */
.beautiful_input.--large {} /* Size Modificator */
```

## ESLint Notes

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
"storybook": "^7.5.1",
"storybook-addon-pseudo-states": "2.1.2",
"typescript": "^5.0.2",
"typescript-plugin-css-modules": "5.0.2",
"vite": "^4.4.5"
},
"readme": "ERROR: No README data found!",
Expand Down
Loading

0 comments on commit 03047f3

Please sign in to comment.