eslint-plugin-react-x 2.3.0 → 2.3.1-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +12 -1
- package/package.json +6 -6
package/dist/index.js
CHANGED
|
@@ -28,7 +28,7 @@ var __export = (all) => {
|
|
|
28
28
|
//#endregion
|
|
29
29
|
//#region package.json
|
|
30
30
|
var name$6 = "eslint-plugin-react-x";
|
|
31
|
-
var version = "2.3.0";
|
|
31
|
+
var version = "2.3.1-beta.0";
|
|
32
32
|
|
|
33
33
|
//#endregion
|
|
34
34
|
//#region src/utils/create-rule.ts
|
|
@@ -149,9 +149,20 @@ function create$62(context) {
|
|
|
149
149
|
if (child.type !== AST_NODE_TYPES.JSXText || !child.value.endsWith("$")) continue;
|
|
150
150
|
if (node.children[index + 1]?.type !== AST_NODE_TYPES.JSXExpressionContainer) continue;
|
|
151
151
|
if (child.value === "$" && node.children.length === 2) continue;
|
|
152
|
+
const pos = child.loc.end;
|
|
152
153
|
context.report({
|
|
153
154
|
messageId: "jsxDollar",
|
|
154
155
|
node: child,
|
|
156
|
+
loc: {
|
|
157
|
+
end: {
|
|
158
|
+
column: pos.column,
|
|
159
|
+
line: pos.line
|
|
160
|
+
},
|
|
161
|
+
start: {
|
|
162
|
+
column: pos.column - 1,
|
|
163
|
+
line: pos.line
|
|
164
|
+
}
|
|
165
|
+
},
|
|
155
166
|
suggest: [{
|
|
156
167
|
messageId: "removeDollarSign",
|
|
157
168
|
fix(fixer) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eslint-plugin-react-x",
|
|
3
|
-
"version": "2.3.0",
|
|
3
|
+
"version": "2.3.1-beta.0",
|
|
4
4
|
"description": "A set of composable ESLint rules for for libraries and frameworks that use React as a UI runtime.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -46,11 +46,11 @@
|
|
|
46
46
|
"string-ts": "^2.2.1",
|
|
47
47
|
"ts-api-utils": "^2.1.0",
|
|
48
48
|
"ts-pattern": "^5.9.0",
|
|
49
|
-
"@eslint-react/
|
|
50
|
-
"@eslint-react/
|
|
51
|
-
"@eslint-react/eff": "2.3.0",
|
|
52
|
-
"@eslint-react/shared": "2.3.0",
|
|
53
|
-
"@eslint-react/var": "2.3.0"
|
|
49
|
+
"@eslint-react/core": "2.3.1-beta.0",
|
|
50
|
+
"@eslint-react/ast": "2.3.1-beta.0",
|
|
51
|
+
"@eslint-react/eff": "2.3.1-beta.0",
|
|
52
|
+
"@eslint-react/shared": "2.3.1-beta.0",
|
|
53
|
+
"@eslint-react/var": "2.3.1-beta.0"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"@types/react": "^19.2.2",
|