Skip to content

Commit

Permalink
docs: add no-important rule docs
Browse files Browse the repository at this point in the history
  • Loading branch information
yannbertrand committed Nov 28, 2024
1 parent 6440128 commit db8d19e
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ export default [
| :--------------------------------------------------------------- | :------------------------------- | :-------------: |
| [`no-duplicate-imports`](./docs/rules/no-duplicate-imports.md) | Disallow duplicate @import rules | yes |
| [`no-empty-blocks`](./docs/rules/no-empty-blocks.md) | Disallow empty blocks | yes |
| [`no-important`](./docs/rules/no-important.md) | Disallow !important annotations | yes |
| [`no-invalid-at-rules`](./docs/rules/no-invalid-at-rules.md) | Disallow invalid at-rules | yes |
| [`no-invalid-properties`](./docs/rules/no-invalid-properties.md) | Disallow invalid properties | yes |

Expand Down
21 changes: 21 additions & 0 deletions docs/rules/no-important.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# no-important

Disallow `!important` annotations.

## Background

Needing !important indicates there may be a larger underlying issue.

## Rule Details

Examples of incorrect code:

```css
a {
color: red !important;
}

a .link {
font-size: padding: 10px 20px 30px 40px !important;
}
```

0 comments on commit db8d19e

Please sign in to comment.