822 lines
33 KiB
TypeScript
822 lines
33 KiB
TypeScript
// Generated by dts-bundle v0.7.3
|
|
// Dependencies for this module:
|
|
// ../jsonc-eslint-parser
|
|
// ../json-schema
|
|
// ../eslint
|
|
// ../estree
|
|
// ../@humanwhocodes/momoa
|
|
|
|
declare module 'eslint-plugin-jsonc' {
|
|
import type { RuleModule } from "eslint-plugin-jsonc/types";
|
|
import * as meta from "eslint-plugin-jsonc/meta";
|
|
import { parseForESLint, parseJSON, traverseNodes, AST, getStaticJSONValue } from "jsonc-eslint-parser";
|
|
const configs: {
|
|
base: {
|
|
plugins: string[];
|
|
overrides: {
|
|
files: string[];
|
|
parser: string;
|
|
rules: {
|
|
strict: string;
|
|
"no-unused-expressions": string;
|
|
"no-unused-vars": string;
|
|
};
|
|
}[];
|
|
};
|
|
"auto-config": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/auto": string;
|
|
};
|
|
};
|
|
"recommended-with-json": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/comma-dangle": string;
|
|
"jsonc/no-bigint-literals": string;
|
|
"jsonc/no-binary-expression": string;
|
|
"jsonc/no-binary-numeric-literals": string;
|
|
"jsonc/no-comments": string;
|
|
"jsonc/no-dupe-keys": string;
|
|
"jsonc/no-escape-sequence-in-identifier": string;
|
|
"jsonc/no-floating-decimal": string;
|
|
"jsonc/no-hexadecimal-numeric-literals": string;
|
|
"jsonc/no-infinity": string;
|
|
"jsonc/no-multi-str": string;
|
|
"jsonc/no-nan": string;
|
|
"jsonc/no-number-props": string;
|
|
"jsonc/no-numeric-separators": string;
|
|
"jsonc/no-octal-numeric-literals": string;
|
|
"jsonc/no-octal": string;
|
|
"jsonc/no-parenthesized": string;
|
|
"jsonc/no-plus-sign": string;
|
|
"jsonc/no-regexp-literals": string;
|
|
"jsonc/no-sparse-arrays": string;
|
|
"jsonc/no-template-literals": string;
|
|
"jsonc/no-undefined-value": string;
|
|
"jsonc/no-unicode-codepoint-escapes": string;
|
|
"jsonc/no-useless-escape": string;
|
|
"jsonc/quote-props": string;
|
|
"jsonc/quotes": string;
|
|
"jsonc/space-unary-ops": string;
|
|
"jsonc/valid-json-number": string;
|
|
"jsonc/vue-custom-block/no-parsing-error": string;
|
|
};
|
|
};
|
|
"recommended-with-jsonc": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/no-bigint-literals": string;
|
|
"jsonc/no-binary-expression": string;
|
|
"jsonc/no-binary-numeric-literals": string;
|
|
"jsonc/no-dupe-keys": string;
|
|
"jsonc/no-escape-sequence-in-identifier": string;
|
|
"jsonc/no-floating-decimal": string;
|
|
"jsonc/no-hexadecimal-numeric-literals": string;
|
|
"jsonc/no-infinity": string;
|
|
"jsonc/no-multi-str": string;
|
|
"jsonc/no-nan": string;
|
|
"jsonc/no-number-props": string;
|
|
"jsonc/no-numeric-separators": string;
|
|
"jsonc/no-octal-numeric-literals": string;
|
|
"jsonc/no-octal": string;
|
|
"jsonc/no-parenthesized": string;
|
|
"jsonc/no-plus-sign": string;
|
|
"jsonc/no-regexp-literals": string;
|
|
"jsonc/no-sparse-arrays": string;
|
|
"jsonc/no-template-literals": string;
|
|
"jsonc/no-undefined-value": string;
|
|
"jsonc/no-unicode-codepoint-escapes": string;
|
|
"jsonc/no-useless-escape": string;
|
|
"jsonc/quote-props": string;
|
|
"jsonc/quotes": string;
|
|
"jsonc/space-unary-ops": string;
|
|
"jsonc/valid-json-number": string;
|
|
"jsonc/vue-custom-block/no-parsing-error": string;
|
|
};
|
|
};
|
|
"recommended-with-json5": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/no-bigint-literals": string;
|
|
"jsonc/no-binary-expression": string;
|
|
"jsonc/no-binary-numeric-literals": string;
|
|
"jsonc/no-dupe-keys": string;
|
|
"jsonc/no-escape-sequence-in-identifier": string;
|
|
"jsonc/no-number-props": string;
|
|
"jsonc/no-numeric-separators": string;
|
|
"jsonc/no-octal-numeric-literals": string;
|
|
"jsonc/no-octal": string;
|
|
"jsonc/no-parenthesized": string;
|
|
"jsonc/no-regexp-literals": string;
|
|
"jsonc/no-sparse-arrays": string;
|
|
"jsonc/no-template-literals": string;
|
|
"jsonc/no-undefined-value": string;
|
|
"jsonc/no-unicode-codepoint-escapes": string;
|
|
"jsonc/no-useless-escape": string;
|
|
"jsonc/space-unary-ops": string;
|
|
"jsonc/vue-custom-block/no-parsing-error": string;
|
|
};
|
|
};
|
|
prettier: {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/array-bracket-newline": string;
|
|
"jsonc/array-bracket-spacing": string;
|
|
"jsonc/array-element-newline": string;
|
|
"jsonc/comma-dangle": string;
|
|
"jsonc/comma-style": string;
|
|
"jsonc/indent": string;
|
|
"jsonc/key-spacing": string;
|
|
"jsonc/no-floating-decimal": string;
|
|
"jsonc/object-curly-newline": string;
|
|
"jsonc/object-curly-spacing": string;
|
|
"jsonc/object-property-newline": string;
|
|
"jsonc/quote-props": string;
|
|
"jsonc/quotes": string;
|
|
"jsonc/space-unary-ops": string;
|
|
};
|
|
};
|
|
all: {
|
|
extends: string[];
|
|
rules: {
|
|
[x: string]: string;
|
|
};
|
|
};
|
|
"flat/base": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
})[];
|
|
"flat/recommended-with-json": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/comma-dangle": "error";
|
|
"jsonc/no-bigint-literals": "error";
|
|
"jsonc/no-binary-expression": "error";
|
|
"jsonc/no-binary-numeric-literals": "error";
|
|
"jsonc/no-comments": "error";
|
|
"jsonc/no-dupe-keys": "error";
|
|
"jsonc/no-escape-sequence-in-identifier": "error";
|
|
"jsonc/no-floating-decimal": "error";
|
|
"jsonc/no-hexadecimal-numeric-literals": "error";
|
|
"jsonc/no-infinity": "error";
|
|
"jsonc/no-multi-str": "error";
|
|
"jsonc/no-nan": "error";
|
|
"jsonc/no-number-props": "error";
|
|
"jsonc/no-numeric-separators": "error";
|
|
"jsonc/no-octal-numeric-literals": "error";
|
|
"jsonc/no-octal": "error";
|
|
"jsonc/no-parenthesized": "error";
|
|
"jsonc/no-plus-sign": "error";
|
|
"jsonc/no-regexp-literals": "error";
|
|
"jsonc/no-sparse-arrays": "error";
|
|
"jsonc/no-template-literals": "error";
|
|
"jsonc/no-undefined-value": "error";
|
|
"jsonc/no-unicode-codepoint-escapes": "error";
|
|
"jsonc/no-useless-escape": "error";
|
|
"jsonc/quote-props": "error";
|
|
"jsonc/quotes": "error";
|
|
"jsonc/space-unary-ops": "error";
|
|
"jsonc/valid-json-number": "error";
|
|
"jsonc/vue-custom-block/no-parsing-error": "error";
|
|
};
|
|
})[];
|
|
"flat/recommended-with-jsonc": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/no-bigint-literals": "error";
|
|
"jsonc/no-binary-expression": "error";
|
|
"jsonc/no-binary-numeric-literals": "error";
|
|
"jsonc/no-dupe-keys": "error";
|
|
"jsonc/no-escape-sequence-in-identifier": "error";
|
|
"jsonc/no-floating-decimal": "error";
|
|
"jsonc/no-hexadecimal-numeric-literals": "error";
|
|
"jsonc/no-infinity": "error";
|
|
"jsonc/no-multi-str": "error";
|
|
"jsonc/no-nan": "error";
|
|
"jsonc/no-number-props": "error";
|
|
"jsonc/no-numeric-separators": "error";
|
|
"jsonc/no-octal-numeric-literals": "error";
|
|
"jsonc/no-octal": "error";
|
|
"jsonc/no-parenthesized": "error";
|
|
"jsonc/no-plus-sign": "error";
|
|
"jsonc/no-regexp-literals": "error";
|
|
"jsonc/no-sparse-arrays": "error";
|
|
"jsonc/no-template-literals": "error";
|
|
"jsonc/no-undefined-value": "error";
|
|
"jsonc/no-unicode-codepoint-escapes": "error";
|
|
"jsonc/no-useless-escape": "error";
|
|
"jsonc/quote-props": "error";
|
|
"jsonc/quotes": "error";
|
|
"jsonc/space-unary-ops": "error";
|
|
"jsonc/valid-json-number": "error";
|
|
"jsonc/vue-custom-block/no-parsing-error": "error";
|
|
};
|
|
})[];
|
|
"flat/recommended-with-json5": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/no-bigint-literals": "error";
|
|
"jsonc/no-binary-expression": "error";
|
|
"jsonc/no-binary-numeric-literals": "error";
|
|
"jsonc/no-dupe-keys": "error";
|
|
"jsonc/no-escape-sequence-in-identifier": "error";
|
|
"jsonc/no-number-props": "error";
|
|
"jsonc/no-numeric-separators": "error";
|
|
"jsonc/no-octal-numeric-literals": "error";
|
|
"jsonc/no-octal": "error";
|
|
"jsonc/no-parenthesized": "error";
|
|
"jsonc/no-regexp-literals": "error";
|
|
"jsonc/no-sparse-arrays": "error";
|
|
"jsonc/no-template-literals": "error";
|
|
"jsonc/no-undefined-value": "error";
|
|
"jsonc/no-unicode-codepoint-escapes": "error";
|
|
"jsonc/no-useless-escape": "error";
|
|
"jsonc/space-unary-ops": "error";
|
|
"jsonc/vue-custom-block/no-parsing-error": "error";
|
|
};
|
|
})[];
|
|
"flat/prettier": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/array-bracket-newline": "off";
|
|
"jsonc/array-bracket-spacing": "off";
|
|
"jsonc/array-element-newline": "off";
|
|
"jsonc/comma-dangle": "off";
|
|
"jsonc/comma-style": "off";
|
|
"jsonc/indent": "off";
|
|
"jsonc/key-spacing": "off";
|
|
"jsonc/no-floating-decimal": "off";
|
|
"jsonc/object-curly-newline": "off";
|
|
"jsonc/object-curly-spacing": "off";
|
|
"jsonc/object-property-newline": "off";
|
|
"jsonc/quote-props": "off";
|
|
"jsonc/quotes": "off";
|
|
"jsonc/space-unary-ops": "off";
|
|
};
|
|
})[];
|
|
"flat/all": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
[rule: string]: import("eslint").Linter.RuleEntry<any[]>;
|
|
};
|
|
})[];
|
|
};
|
|
const rules: {
|
|
[key: string]: RuleModule<unknown[]>;
|
|
};
|
|
const _default: {
|
|
meta: typeof meta;
|
|
configs: {
|
|
base: {
|
|
plugins: string[];
|
|
overrides: {
|
|
files: string[];
|
|
parser: string;
|
|
rules: {
|
|
strict: string;
|
|
"no-unused-expressions": string;
|
|
"no-unused-vars": string;
|
|
};
|
|
}[];
|
|
};
|
|
"auto-config": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/auto": string;
|
|
};
|
|
};
|
|
"recommended-with-json": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/comma-dangle": string;
|
|
"jsonc/no-bigint-literals": string;
|
|
"jsonc/no-binary-expression": string;
|
|
"jsonc/no-binary-numeric-literals": string;
|
|
"jsonc/no-comments": string;
|
|
"jsonc/no-dupe-keys": string;
|
|
"jsonc/no-escape-sequence-in-identifier": string;
|
|
"jsonc/no-floating-decimal": string;
|
|
"jsonc/no-hexadecimal-numeric-literals": string;
|
|
"jsonc/no-infinity": string;
|
|
"jsonc/no-multi-str": string;
|
|
"jsonc/no-nan": string;
|
|
"jsonc/no-number-props": string;
|
|
"jsonc/no-numeric-separators": string;
|
|
"jsonc/no-octal-numeric-literals": string;
|
|
"jsonc/no-octal": string;
|
|
"jsonc/no-parenthesized": string;
|
|
"jsonc/no-plus-sign": string;
|
|
"jsonc/no-regexp-literals": string;
|
|
"jsonc/no-sparse-arrays": string;
|
|
"jsonc/no-template-literals": string;
|
|
"jsonc/no-undefined-value": string;
|
|
"jsonc/no-unicode-codepoint-escapes": string;
|
|
"jsonc/no-useless-escape": string;
|
|
"jsonc/quote-props": string;
|
|
"jsonc/quotes": string;
|
|
"jsonc/space-unary-ops": string;
|
|
"jsonc/valid-json-number": string;
|
|
"jsonc/vue-custom-block/no-parsing-error": string;
|
|
};
|
|
};
|
|
"recommended-with-jsonc": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/no-bigint-literals": string;
|
|
"jsonc/no-binary-expression": string;
|
|
"jsonc/no-binary-numeric-literals": string;
|
|
"jsonc/no-dupe-keys": string;
|
|
"jsonc/no-escape-sequence-in-identifier": string;
|
|
"jsonc/no-floating-decimal": string;
|
|
"jsonc/no-hexadecimal-numeric-literals": string;
|
|
"jsonc/no-infinity": string;
|
|
"jsonc/no-multi-str": string;
|
|
"jsonc/no-nan": string;
|
|
"jsonc/no-number-props": string;
|
|
"jsonc/no-numeric-separators": string;
|
|
"jsonc/no-octal-numeric-literals": string;
|
|
"jsonc/no-octal": string;
|
|
"jsonc/no-parenthesized": string;
|
|
"jsonc/no-plus-sign": string;
|
|
"jsonc/no-regexp-literals": string;
|
|
"jsonc/no-sparse-arrays": string;
|
|
"jsonc/no-template-literals": string;
|
|
"jsonc/no-undefined-value": string;
|
|
"jsonc/no-unicode-codepoint-escapes": string;
|
|
"jsonc/no-useless-escape": string;
|
|
"jsonc/quote-props": string;
|
|
"jsonc/quotes": string;
|
|
"jsonc/space-unary-ops": string;
|
|
"jsonc/valid-json-number": string;
|
|
"jsonc/vue-custom-block/no-parsing-error": string;
|
|
};
|
|
};
|
|
"recommended-with-json5": {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/no-bigint-literals": string;
|
|
"jsonc/no-binary-expression": string;
|
|
"jsonc/no-binary-numeric-literals": string;
|
|
"jsonc/no-dupe-keys": string;
|
|
"jsonc/no-escape-sequence-in-identifier": string;
|
|
"jsonc/no-number-props": string;
|
|
"jsonc/no-numeric-separators": string;
|
|
"jsonc/no-octal-numeric-literals": string;
|
|
"jsonc/no-octal": string;
|
|
"jsonc/no-parenthesized": string;
|
|
"jsonc/no-regexp-literals": string;
|
|
"jsonc/no-sparse-arrays": string;
|
|
"jsonc/no-template-literals": string;
|
|
"jsonc/no-undefined-value": string;
|
|
"jsonc/no-unicode-codepoint-escapes": string;
|
|
"jsonc/no-useless-escape": string;
|
|
"jsonc/space-unary-ops": string;
|
|
"jsonc/vue-custom-block/no-parsing-error": string;
|
|
};
|
|
};
|
|
prettier: {
|
|
extends: string[];
|
|
rules: {
|
|
"jsonc/array-bracket-newline": string;
|
|
"jsonc/array-bracket-spacing": string;
|
|
"jsonc/array-element-newline": string;
|
|
"jsonc/comma-dangle": string;
|
|
"jsonc/comma-style": string;
|
|
"jsonc/indent": string;
|
|
"jsonc/key-spacing": string;
|
|
"jsonc/no-floating-decimal": string;
|
|
"jsonc/object-curly-newline": string;
|
|
"jsonc/object-curly-spacing": string;
|
|
"jsonc/object-property-newline": string;
|
|
"jsonc/quote-props": string;
|
|
"jsonc/quotes": string;
|
|
"jsonc/space-unary-ops": string;
|
|
};
|
|
};
|
|
all: {
|
|
extends: string[];
|
|
rules: {
|
|
[x: string]: string;
|
|
};
|
|
};
|
|
"flat/base": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
})[];
|
|
"flat/recommended-with-json": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/comma-dangle": "error";
|
|
"jsonc/no-bigint-literals": "error";
|
|
"jsonc/no-binary-expression": "error";
|
|
"jsonc/no-binary-numeric-literals": "error";
|
|
"jsonc/no-comments": "error";
|
|
"jsonc/no-dupe-keys": "error";
|
|
"jsonc/no-escape-sequence-in-identifier": "error";
|
|
"jsonc/no-floating-decimal": "error";
|
|
"jsonc/no-hexadecimal-numeric-literals": "error";
|
|
"jsonc/no-infinity": "error";
|
|
"jsonc/no-multi-str": "error";
|
|
"jsonc/no-nan": "error";
|
|
"jsonc/no-number-props": "error";
|
|
"jsonc/no-numeric-separators": "error";
|
|
"jsonc/no-octal-numeric-literals": "error";
|
|
"jsonc/no-octal": "error";
|
|
"jsonc/no-parenthesized": "error";
|
|
"jsonc/no-plus-sign": "error";
|
|
"jsonc/no-regexp-literals": "error";
|
|
"jsonc/no-sparse-arrays": "error";
|
|
"jsonc/no-template-literals": "error";
|
|
"jsonc/no-undefined-value": "error";
|
|
"jsonc/no-unicode-codepoint-escapes": "error";
|
|
"jsonc/no-useless-escape": "error";
|
|
"jsonc/quote-props": "error";
|
|
"jsonc/quotes": "error";
|
|
"jsonc/space-unary-ops": "error";
|
|
"jsonc/valid-json-number": "error";
|
|
"jsonc/vue-custom-block/no-parsing-error": "error";
|
|
};
|
|
})[];
|
|
"flat/recommended-with-jsonc": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/no-bigint-literals": "error";
|
|
"jsonc/no-binary-expression": "error";
|
|
"jsonc/no-binary-numeric-literals": "error";
|
|
"jsonc/no-dupe-keys": "error";
|
|
"jsonc/no-escape-sequence-in-identifier": "error";
|
|
"jsonc/no-floating-decimal": "error";
|
|
"jsonc/no-hexadecimal-numeric-literals": "error";
|
|
"jsonc/no-infinity": "error";
|
|
"jsonc/no-multi-str": "error";
|
|
"jsonc/no-nan": "error";
|
|
"jsonc/no-number-props": "error";
|
|
"jsonc/no-numeric-separators": "error";
|
|
"jsonc/no-octal-numeric-literals": "error";
|
|
"jsonc/no-octal": "error";
|
|
"jsonc/no-parenthesized": "error";
|
|
"jsonc/no-plus-sign": "error";
|
|
"jsonc/no-regexp-literals": "error";
|
|
"jsonc/no-sparse-arrays": "error";
|
|
"jsonc/no-template-literals": "error";
|
|
"jsonc/no-undefined-value": "error";
|
|
"jsonc/no-unicode-codepoint-escapes": "error";
|
|
"jsonc/no-useless-escape": "error";
|
|
"jsonc/quote-props": "error";
|
|
"jsonc/quotes": "error";
|
|
"jsonc/space-unary-ops": "error";
|
|
"jsonc/valid-json-number": "error";
|
|
"jsonc/vue-custom-block/no-parsing-error": "error";
|
|
};
|
|
})[];
|
|
"flat/recommended-with-json5": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/no-bigint-literals": "error";
|
|
"jsonc/no-binary-expression": "error";
|
|
"jsonc/no-binary-numeric-literals": "error";
|
|
"jsonc/no-dupe-keys": "error";
|
|
"jsonc/no-escape-sequence-in-identifier": "error";
|
|
"jsonc/no-number-props": "error";
|
|
"jsonc/no-numeric-separators": "error";
|
|
"jsonc/no-octal-numeric-literals": "error";
|
|
"jsonc/no-octal": "error";
|
|
"jsonc/no-parenthesized": "error";
|
|
"jsonc/no-regexp-literals": "error";
|
|
"jsonc/no-sparse-arrays": "error";
|
|
"jsonc/no-template-literals": "error";
|
|
"jsonc/no-undefined-value": "error";
|
|
"jsonc/no-unicode-codepoint-escapes": "error";
|
|
"jsonc/no-useless-escape": "error";
|
|
"jsonc/space-unary-ops": "error";
|
|
"jsonc/vue-custom-block/no-parsing-error": "error";
|
|
};
|
|
})[];
|
|
"flat/prettier": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
"jsonc/array-bracket-newline": "off";
|
|
"jsonc/array-bracket-spacing": "off";
|
|
"jsonc/array-element-newline": "off";
|
|
"jsonc/comma-dangle": "off";
|
|
"jsonc/comma-style": "off";
|
|
"jsonc/indent": "off";
|
|
"jsonc/key-spacing": "off";
|
|
"jsonc/no-floating-decimal": "off";
|
|
"jsonc/object-curly-newline": "off";
|
|
"jsonc/object-curly-spacing": "off";
|
|
"jsonc/object-property-newline": "off";
|
|
"jsonc/quote-props": "off";
|
|
"jsonc/quotes": "off";
|
|
"jsonc/space-unary-ops": "off";
|
|
};
|
|
})[];
|
|
"flat/all": ({
|
|
plugins: {
|
|
readonly jsonc: import("eslint").ESLint.Plugin;
|
|
};
|
|
files?: undefined;
|
|
languageOptions?: undefined;
|
|
rules?: undefined;
|
|
} | {
|
|
files: string[];
|
|
languageOptions: {
|
|
parser: typeof import("jsonc-eslint-parser");
|
|
};
|
|
rules: {
|
|
strict: "off";
|
|
"no-unused-expressions": "off";
|
|
"no-unused-vars": "off";
|
|
};
|
|
plugins?: undefined;
|
|
} | {
|
|
rules: {
|
|
[rule: string]: import("eslint").Linter.RuleEntry<any[]>;
|
|
};
|
|
})[];
|
|
};
|
|
rules: {
|
|
[key: string]: RuleModule<unknown[]>;
|
|
};
|
|
parseForESLint: typeof parseForESLint;
|
|
parseJSON: typeof parseJSON;
|
|
traverseNodes: typeof traverseNodes;
|
|
getStaticJSONValue: typeof getStaticJSONValue;
|
|
};
|
|
export default _default;
|
|
export { meta, configs, rules, AST, parseForESLint, parseJSON, traverseNodes, getStaticJSONValue, };
|
|
}
|
|
|
|
declare module 'eslint-plugin-jsonc/types' {
|
|
import type { JSONSchema4 } from "json-schema";
|
|
import type { Rule } from "eslint";
|
|
import type { BuiltInRuleListenerExits, BuiltInRuleListeners, RuleListener } from "jsonc-eslint-parser";
|
|
import type { AST as ESLintAST } from "eslint";
|
|
import type * as ESTree from "estree";
|
|
import type { AnyNode } from "@humanwhocodes/momoa";
|
|
export type Token = ESLintAST.Token;
|
|
export type Comment = ESTree.Comment;
|
|
export { RuleListener };
|
|
export type MomoaNode = AnyNode;
|
|
type MomoaRuleFunction<Node extends MomoaNode = never> = (node: Node) => void;
|
|
type MomoaBuiltInRuleListeners = {
|
|
[Node in MomoaNode as Node["type"]]?: MomoaRuleFunction<Node>;
|
|
};
|
|
type MomoaBuiltInRuleListenerExits = {
|
|
[Node in MomoaNode as `${Node["type"]}:exit`]?: MomoaRuleFunction<Node>;
|
|
};
|
|
export type MomoaRuleListener = MomoaBuiltInRuleListeners & MomoaBuiltInRuleListenerExits;
|
|
export type BaseRuleListener = MomoaRuleListener & BuiltInRuleListeners & BuiltInRuleListenerExits;
|
|
export interface RuleModule<RuleOptions = unknown[]> {
|
|
meta: RuleMetaData;
|
|
jsoncDefineRule: PartialRuleModule<RuleOptions>;
|
|
create(context: Rule.RuleContext & {
|
|
options: RuleOptions;
|
|
}): RuleListener;
|
|
}
|
|
export interface RuleMetaData {
|
|
docs: {
|
|
description: string;
|
|
recommended: ("json" | "jsonc" | "json5")[] | null;
|
|
url: string;
|
|
ruleId: string;
|
|
ruleName: string;
|
|
default?: "error" | "warn";
|
|
extensionRule: boolean | string | {
|
|
plugin: string;
|
|
url: string;
|
|
};
|
|
layout: boolean;
|
|
};
|
|
messages: {
|
|
[messageId: string]: string;
|
|
};
|
|
fixable?: "code" | "whitespace";
|
|
hasSuggestions?: boolean;
|
|
schema: false | JSONSchema4 | JSONSchema4[];
|
|
deprecated?: boolean;
|
|
replacedBy?: [];
|
|
type: "problem" | "suggestion" | "layout";
|
|
}
|
|
export interface PartialRuleModule<RuleOptions = unknown[]> {
|
|
meta: PartialRuleMetaData;
|
|
create: (context: Rule.RuleContext & {
|
|
options: RuleOptions;
|
|
}, params: {
|
|
customBlock: boolean;
|
|
}) => BaseRuleListener;
|
|
}
|
|
export interface PartialRuleMetaData {
|
|
docs: {
|
|
description: string;
|
|
recommended: ("json" | "jsonc" | "json5")[] | null;
|
|
default?: "error" | "warn";
|
|
extensionRule: boolean | string | {
|
|
plugin: string;
|
|
url: string;
|
|
};
|
|
layout: boolean;
|
|
};
|
|
messages: {
|
|
[messageId: string]: string;
|
|
};
|
|
fixable?: "code" | "whitespace";
|
|
hasSuggestions?: boolean;
|
|
defaultOptions?: any[];
|
|
schema: false | JSONSchema4 | JSONSchema4[];
|
|
deprecated?: boolean;
|
|
replacedBy?: [];
|
|
type: "problem" | "suggestion" | "layout";
|
|
}
|
|
}
|
|
|
|
declare module 'eslint-plugin-jsonc/meta' {
|
|
export const name: "eslint-plugin-jsonc";
|
|
export const version: "2.20.1";
|
|
}
|
|
|