Skip to content

Commit a195c2e

Browse files
committed
Add jsx-dollar rule to plugin and docs
1 parent 1b9a179 commit a195c2e

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

apps/website/content/docs/rules/overview.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ full: true
2727

2828
| Rule || 🌟 | Description | `react` |
2929
| :----------------------------------------------------------------------------------- | :-----: | :-------: | :-------------------------------------------------------------------------------------------------- | :------: |
30+
| [`jsx-dollar`](./jsx-dollar) | 0️⃣ 0️⃣ | | Prevents unnecessary dollar signs (`$`) from being inserted before an expression in JSX | |
3031
| [`jsx-key-before-spread`](./jsx-key-before-spread) | 1️⃣ 1️⃣ | | Enforces that the 'key' prop is placed before the spread prop in JSX elements | |
3132
| [`jsx-no-comment-textnodes`](./jsx-no-comment-textnodes) | 1️⃣ 1️⃣ | | Prevents comments from being inserted as text nodes | |
3233
| [`jsx-no-duplicate-props`](./jsx-no-duplicate-props) | 1️⃣ 1️⃣ | | Disallow duplicate props in JSX elements | |

packages/plugins/eslint-plugin-react-x/src/plugin.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import type { CompatiblePlugin } from "@eslint-react/shared";
22

33
import { name, version } from "../package.json";
44

5+
import jsxDollar from "./rules/jsx-dollar";
56
import jsxKeyBeforeSpread from "./rules/jsx-key-before-spread";
67
import jsxNoCommentTextnodes from "./rules/jsx-no-comment-textnodes";
78
import jsxNoDuplicateProps from "./rules/jsx-no-duplicate-props";
@@ -71,6 +72,7 @@ export const plugin: CompatiblePlugin = {
7172
version,
7273
},
7374
rules: {
75+
"jsx-dollar": jsxDollar,
7476
"jsx-key-before-spread": jsxKeyBeforeSpread,
7577
"jsx-no-comment-textnodes": jsxNoCommentTextnodes,
7678
"jsx-no-duplicate-props": jsxNoDuplicateProps,

0 commit comments

Comments
 (0)