Skip to content

Commit 0e0d134

Browse files
committed
docs: improve rules overview page
1 parent 47a58b6 commit 0e0d134

File tree

1 file changed

+26
-26
lines changed

1 file changed

+26
-26
lines changed

apps/website/content/docs/rules/overview.mdx renamed to apps/website/content/docs/rules/overview.md

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ full: true
1616

1717
## Core Rules
1818

19-
| Rule || Features | Description | React |
20-
| :--------------------------------------------------------------------------------- | :- | :------------ | :--------------------------------------------------------------------------------------------------- | :------: |
19+
| Rule || Features | Description | React |
20+
| :----------------------------------------------------------------------------------- | :- | :------------ | :--------------------------------------------------------------------------------------------------- | :------: |
2121
| [`ensure-forward-ref-using-ref`](./ensure-forward-ref-using-ref) | 1️⃣ | `🔍` | Requires that components wrapped with `forwardRef` must have a `ref` parameter. | |
2222
| [`no-access-state-in-setstate`](./no-access-state-in-setstate) | 2️⃣ | `🔍` | Prevents accessing `this.state` inside `setState` calls. | |
2323
| [`no-array-index-key`](./no-array-index-key) | 1️⃣ | `🔍` | Prevents using array `index` as `key`. | |
@@ -70,16 +70,16 @@ full: true
7070

7171
### Deprecated
7272

73-
| Rule | Replaced by |
74-
| :--------------------------------------------------------------------------------- | :--------------------------------------------------------------------- |
75-
| [~~`jsx-uses-vars`~~](jsx-uses-vars) | [`use-jsx-vars`](./use-jsx-vars) |
76-
| [~~`jsx-no-duplicate-props`~~](jsx-no-duplicate-props) | [`no-duplicate-jsx-props`](./no-duplicate-jsx-props) |
77-
| [~~`no-complicated-conditional-rendering`~~](no-complicated-conditional-rendering) | [`no-complex-conditional-rendering`](./no-complex-conditional-rendering) |
73+
| Rule | Replaced by |
74+
| :----------------------------------------------------------------------------- | :----------------------------------------------------------------------- |
75+
| [`jsx-uses-vars`](jsx-uses-vars) | [`use-jsx-vars`](./use-jsx-vars) |
76+
| [`jsx-no-duplicate-props`](jsx-no-duplicate-props) | [`no-duplicate-jsx-props`](./no-duplicate-jsx-props) |
77+
| [`no-complicated-conditional-rendering`](no-complicated-conditional-rendering) | [`no-complex-conditional-rendering`](./no-complex-conditional-rendering) |
7878

7979
## DOM Rules
8080

81-
| Rule || Features | Description |
82-
| :--------------------------------------------------------------------------------------------- | :- | :------------ | :-------------------------------------------------------------------------------------- |
81+
| Rule || Features | Description |
82+
| :----------------------------------------------------------------------------------------------- | :- | :------------ | :-------------------------------------------------------------------------------------- |
8383
| [`no-void-elements-with-children`](./dom-no-void-elements-with-children) | 2️⃣ | `🔍` | Prevents using `children` in void `DOM elements`. |
8484
| [`no-dangerously-set-innerhtml-with-children`](./dom-no-dangerously-set-innerhtml-with-children) | 2️⃣ | `🔍` | Prevents `DOM element` using `dangerouslySetInnerHTML` and `children` at the same time. |
8585
| [`no-dangerously-set-innerhtml`](./dom-no-dangerously-set-innerhtml) | 1️⃣ | `🔍` | Prevents `DOM element` using `dangerouslySetInnerHTML`. |
@@ -95,23 +95,23 @@ full: true
9595

9696
### Deprecated
9797

98-
| Rule | Replaced by |
99-
| :--------------------------------------------------------------------------------- | :--------------------------------------------------------------------- |
100-
| [~~`dom-no-children-in-void-dom-elements`~~](dom-no-children-in-void-dom-elements) | [`no-void-elements-with-children`](./dom-no-void-elements-with-children) |
98+
| Rule | Replaced by |
99+
| :----------------------------------------------------------------------------- | :----------------------------------------------------------------------- |
100+
| [`dom-no-children-in-void-dom-elements`](dom-no-children-in-void-dom-elements) | [`no-void-elements-with-children`](./dom-no-void-elements-with-children) |
101101

102102
## Web API Rules
103103

104-
| Rule || Features | Description |
105-
| :--------------------------------------------------------------- | :- | :------- | :---------------------------------------------------------------- |
104+
| Rule || Features | Description |
105+
| :----------------------------------------------------------------- | :- | :------- | :---------------------------------------------------------------- |
106106
| [`no-leaked-event-listener`](./web-api-no-leaked-event-listener) | 1️⃣ | `🔍` | Prevents leaked `addEventListener` in a component or custom Hook. |
107107
| [`no-leaked-interval`](./web-api-no-leaked-interval) | 1️⃣ | `🔍` | Prevents leaked `setInterval` in a component or custom Hook. |
108108
| [`no-leaked-resize-observer`](./web-api-no-leaked-resize-observer) | 1️⃣ | `🔍` | Prevents leaked `ResizeObserver` in a component or custom Hook. |
109109
| [`no-leaked-timeout`](./web-api-no-leaked-timeout) | 1️⃣ | `🔍` | Prevents leaked `setTimeout` in a component or custom Hook. |
110110

111111
## Hooks Extra Rules
112112

113-
| Rule || Features | Description |
114-
| :------------------------------------------------------------------------------------------------- | :- | :------- | :----------------------------------------------------------------------------------------- |
113+
| Rule || Features | Description |
114+
| :--------------------------------------------------------------------------------------------------- | :- | :------- | :----------------------------------------------------------------------------------------- |
115115
| [`no-direct-set-state-in-use-effect`](./hooks-extra-no-direct-set-state-in-use-effect) | 1️⃣ | `🔍` | Disallow direct calls to the `set` function of `useState` in `useEffect`. |
116116
| [`no-direct-set-state-in-use-layout-effect`](./hooks-extra-no-direct-set-state-in-use-layout-effect) | 0️⃣ | `🔍` | Disallow direct calls to the `set` function of `useState` in `useLayoutEffect`. |
117117
| [`no-unnecessary-use-callback`](./hooks-extra-no-unnecessary-use-callback) | 0️⃣ | `🔍` | Disallow unnecessary usage of `useCallback`. |
@@ -121,26 +121,26 @@ full: true
121121

122122
### Deprecated
123123

124-
| Rule | Replaced by |
125-
| :------------------------------------------------------------------------------------- | :----------------------------------------------------------------------- |
126-
| [~~`no-redundant-custom-hook`~~](hooks-extra-no-useless-custom-hooks) | [`no-useless-custom-hooks`](./hooks-extra-no-useless-custom-hooks) |
127-
| [~~`ensure-custom-hooks-using-other-hooks`~~](hooks-extra-no-useless-custom-hooks) | [`no-useless-custom-hooks`](./hooks-extra-no-useless-custom-hooks) |
128-
| [~~`ensure-use-memo-has-non-empty-deps`~~](ensure-use-memo-has-non-empty-deps) | [`no-unnecessary-use-memo`](./hooks-extra-no-unnecessary-use-memo) |
129-
| [~~`ensure-use-callback-has-non-empty-deps`~~](ensure-use-callback-has-non-empty-deps) | [`no-unnecessary-use-callback`](./hooks-extra-no-unnecessary-use-callback) |
124+
| Rule | Replaced by |
125+
| :--------------------------------------------------------------------------------- | :------------------------------------------------------------------------- |
126+
| [`no-redundant-custom-hook`](hooks-extra-no-useless-custom-hooks) | [`no-useless-custom-hooks`](./hooks-extra-no-useless-custom-hooks) |
127+
| [`ensure-custom-hooks-using-other-hooks`](hooks-extra-no-useless-custom-hooks) | [`no-useless-custom-hooks`](./hooks-extra-no-useless-custom-hooks) |
128+
| [`ensure-use-memo-has-non-empty-deps`](ensure-use-memo-has-non-empty-deps) | [`no-unnecessary-use-memo`](./hooks-extra-no-unnecessary-use-memo) |
129+
| [`ensure-use-callback-has-non-empty-deps`](ensure-use-callback-has-non-empty-deps) | [`no-unnecessary-use-callback`](./hooks-extra-no-unnecessary-use-callback) |
130130

131131
## Naming Convention Rules
132132

133-
| Rule || Features | Description |
134-
| :----------------------------------------------------------- | :- | :------- | :------------------------------------------------------------------------------- |
133+
| Rule || Features | Description |
134+
| :------------------------------------------------------------- | :- | :------- | :------------------------------------------------------------------------------- |
135135
| [`component-name`](./naming-convention-component-name) | 0️⃣ | `🔍` `⚙️` | Enforces naming conventions for components. |
136136
| [`filename`](./naming-convention-filename) | 0️⃣ | `🔍` `⚙️` | Enforces naming convention for JSX files. |
137137
| [`filename-extension`](./naming-convention-filename-extension) | 0️⃣ | `🔍` `⚙️` | Enforces consistent use of the JSX file extension. |
138138
| [`use-state`](./naming-convention-use-state) | 0️⃣ | `🔍` | Enforces destructuring and symmetric naming of `useState` hook value and setter. |
139139

140140
## Debug Rules
141141

142-
| Rule || Features | Description |
143-
| :----------------------------------------------- | :- | :------- | :------------------------------------------------------- |
142+
| Rule || Features | Description |
143+
| :------------------------------------------------- | :- | :------- | :------------------------------------------------------- |
144144
| [`class-component`](./debug-class-component) | 0️⃣ | `🐞` | Reports all class components. |
145145
| [`function-component`](./debug-function-component) | 0️⃣ | `🐞` | Reports all function components. |
146146
| [`hook`](./debug-hook) | 0️⃣ | `🐞` | Reports all react hooks. |

0 commit comments

Comments
 (0)