@o3r/eslint-plugin 11.5.0-prerelease.25 → 11.5.0-prerelease.26
Sign up to get free protection for your applications and to get access to all the features.
- package/package.json +3 -3
- package/src/rules/json/utils.d.ts +0 -17
- package/src/rules/json/utils.js +0 -18
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@o3r/eslint-plugin",
|
3
|
-
"version": "11.5.0-prerelease.
|
3
|
+
"version": "11.5.0-prerelease.26",
|
4
4
|
"publishConfig": {
|
5
5
|
"access": "public"
|
6
6
|
},
|
@@ -70,8 +70,8 @@
|
|
70
70
|
"@eslint/eslintrc": "^3.0.0",
|
71
71
|
"@nx/eslint-plugin": "~19.5.0",
|
72
72
|
"@nx/jest": "~19.5.0",
|
73
|
-
"@o3r/build-helpers": "^11.5.0-prerelease.
|
74
|
-
"@o3r/test-helpers": "^11.5.0-prerelease.
|
73
|
+
"@o3r/build-helpers": "^11.5.0-prerelease.26",
|
74
|
+
"@o3r/test-helpers": "^11.5.0-prerelease.26",
|
75
75
|
"@stylistic/eslint-plugin-ts": "~2.4.0",
|
76
76
|
"@types/eslint": "~9.6.0",
|
77
77
|
"@types/jest": "~29.5.2",
|
@@ -1,5 +1,4 @@
|
|
1
1
|
import { type ParserServices, TSESLint } from '@typescript-eslint/utils';
|
2
|
-
import type { AST } from 'jsonc-eslint-parser';
|
3
2
|
/** Basic interface for the Parser Services object provided by jsonc-eslint-parser */
|
4
3
|
type JsoncParserServices = ParserServices & {
|
5
4
|
isJSON: boolean;
|
@@ -9,22 +8,6 @@ type JsoncParserServices = ParserServices & {
|
|
9
8
|
* @param parserServices Parser services object
|
10
9
|
*/
|
11
10
|
export declare function isJsoncParserServices(parserServices: any): parserServices is JsoncParserServices;
|
12
|
-
/**
|
13
|
-
*
|
14
|
-
* @param node
|
15
|
-
* @param node.type
|
16
|
-
*/
|
17
|
-
export declare function isProperty(node?: {
|
18
|
-
type: string;
|
19
|
-
}): node is AST.JSONProperty;
|
20
|
-
/**
|
21
|
-
*
|
22
|
-
* @param node
|
23
|
-
* @param node.type
|
24
|
-
*/
|
25
|
-
export declare function isObjectExpression(node?: {
|
26
|
-
type: string;
|
27
|
-
}): node is AST.JSONObjectExpression;
|
28
11
|
/**
|
29
12
|
* Retrieve the json parser services object or throw if the invalid parser is used
|
30
13
|
* @param context Rule context
|
package/src/rules/json/utils.js
CHANGED
@@ -1,8 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
exports.isJsoncParserServices = isJsoncParserServices;
|
4
|
-
exports.isProperty = isProperty;
|
5
|
-
exports.isObjectExpression = isObjectExpression;
|
6
4
|
exports.getJsoncParserServices = getJsoncParserServices;
|
7
5
|
exports.ensureJsoncParser = ensureJsoncParser;
|
8
6
|
/**
|
@@ -12,22 +10,6 @@ exports.ensureJsoncParser = ensureJsoncParser;
|
|
12
10
|
function isJsoncParserServices(parserServices) {
|
13
11
|
return !!parserServices && typeof parserServices.isJSON !== 'undefined';
|
14
12
|
}
|
15
|
-
/**
|
16
|
-
*
|
17
|
-
* @param node
|
18
|
-
* @param node.type
|
19
|
-
*/
|
20
|
-
function isProperty(node) {
|
21
|
-
return !!node && node.type !== 'JSONProperty';
|
22
|
-
}
|
23
|
-
/**
|
24
|
-
*
|
25
|
-
* @param node
|
26
|
-
* @param node.type
|
27
|
-
*/
|
28
|
-
function isObjectExpression(node) {
|
29
|
-
return !!node && node.type !== 'JSONObjectExpression';
|
30
|
-
}
|
31
13
|
/**
|
32
14
|
* Retrieve the json parser services object or throw if the invalid parser is used
|
33
15
|
* @param context Rule context
|