@vue-jsx-vapor/eslint 2.3.0 → 2.3.2
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.cjs +523 -597
- package/dist/index.d.cts +34 -39
- package/dist/index.d.ts +34 -39
- package/dist/index.js +496 -597
- package/package.json +3 -3
package/dist/index.d.cts
CHANGED
|
@@ -1,41 +1,34 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import * as _typescript_eslint_utils_ts_eslint from '@typescript-eslint/utils/ts-eslint';
|
|
1
|
+
import { ESLint, Linter } from "eslint";
|
|
2
|
+
import { RuleListener, RuleModule } from "@typescript-eslint/utils/ts-eslint";
|
|
4
3
|
|
|
4
|
+
//#region src/rules/define-style/types.d.ts
|
|
5
5
|
interface DefineStyleSchema0 {
|
|
6
|
-
|
|
6
|
+
tabWidth?: number;
|
|
7
7
|
}
|
|
8
|
+
type DefineStyleRuleOptions = [DefineStyleSchema0?];
|
|
9
|
+
type MessageIds$1 = 'define-style' | 'define-style-syntax-error';
|
|
8
10
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
//#endregion
|
|
12
|
+
//#region src/rules/jsx-sort-props/types.d.ts
|
|
12
13
|
interface JsxSortPropsSchema0 {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
14
|
+
callbacksLast?: boolean;
|
|
15
|
+
shorthandFirst?: boolean;
|
|
16
|
+
shorthandLast?: boolean;
|
|
17
|
+
multiline?: 'ignore' | 'first' | 'last';
|
|
18
|
+
ignoreCase?: boolean;
|
|
19
|
+
noSortAlphabetically?: boolean;
|
|
20
|
+
reservedFirst?: string[] | boolean;
|
|
21
|
+
reservedLast?: string[];
|
|
22
|
+
locale?: string;
|
|
22
23
|
}
|
|
24
|
+
type JsxSortPropsRuleOptions = [JsxSortPropsSchema0?];
|
|
25
|
+
type MessageIds = 'listIsEmpty' | 'listReservedPropsFirst' | 'listReservedPropsLast' | 'listCallbacksLast' | 'listShorthandFirst' | 'listShorthandLast' | 'listMultilineFirst' | 'listMultilineLast' | 'sortPropsByAlpha';
|
|
23
26
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
| 'listIsEmpty'
|
|
27
|
-
| 'listReservedPropsFirst'
|
|
28
|
-
| 'listReservedPropsLast'
|
|
29
|
-
| 'listCallbacksLast'
|
|
30
|
-
| 'listShorthandFirst'
|
|
31
|
-
| 'listShorthandLast'
|
|
32
|
-
| 'listMultilineFirst'
|
|
33
|
-
| 'listMultilineLast'
|
|
34
|
-
| 'sortPropsByAlpha'
|
|
35
|
-
|
|
27
|
+
//#endregion
|
|
28
|
+
//#region src/rules/index.d.ts
|
|
36
29
|
declare const ruleOptions: {
|
|
37
|
-
'jsx-sort-props':
|
|
38
|
-
'define-style':
|
|
30
|
+
'jsx-sort-props': RuleModule<MessageIds, JsxSortPropsRuleOptions, unknown, RuleListener>;
|
|
31
|
+
'define-style': RuleModule<MessageIds$1, DefineStyleRuleOptions, unknown, RuleListener>;
|
|
39
32
|
};
|
|
40
33
|
interface RuleOptions {
|
|
41
34
|
'vue-jsx-vapor/jsx-sort-props': JsxSortPropsRuleOptions;
|
|
@@ -45,15 +38,16 @@ type Rules = Partial<{
|
|
|
45
38
|
[K in keyof RuleOptions]: Linter.RuleSeverity | [Linter.RuleSeverity, ...RuleOptions[K]];
|
|
46
39
|
}>;
|
|
47
40
|
|
|
41
|
+
//#endregion
|
|
42
|
+
//#region src/index.d.ts
|
|
48
43
|
declare const plugins: {
|
|
49
44
|
'vue-jsx-vapor': {
|
|
50
45
|
rules: {
|
|
51
|
-
'jsx-sort-props':
|
|
52
|
-
'define-style':
|
|
46
|
+
'jsx-sort-props': RuleModule<MessageIds, JsxSortPropsRuleOptions, unknown, RuleListener>;
|
|
47
|
+
'define-style': RuleModule<MessageIds$1, DefineStyleRuleOptions, unknown, RuleListener>;
|
|
53
48
|
};
|
|
54
49
|
};
|
|
55
50
|
};
|
|
56
|
-
|
|
57
51
|
declare const _default: ({ rules, ...options }?: Linter.Config<Rules>) => {
|
|
58
52
|
name: string;
|
|
59
53
|
files?: Array<string | string[]>;
|
|
@@ -65,18 +59,19 @@ declare const _default: ({ rules, ...options }?: Linter.Config<Rules>) => {
|
|
|
65
59
|
plugins: {
|
|
66
60
|
'vue-jsx-vapor': {
|
|
67
61
|
rules: {
|
|
68
|
-
'jsx-sort-props':
|
|
69
|
-
'define-style':
|
|
62
|
+
'jsx-sort-props': RuleModule<MessageIds, JsxSortPropsRuleOptions, unknown, RuleListener>;
|
|
63
|
+
'define-style': RuleModule<MessageIds$1, DefineStyleRuleOptions, unknown, RuleListener>;
|
|
70
64
|
};
|
|
71
65
|
};
|
|
72
|
-
} | Record<string,
|
|
66
|
+
} | Record<string, ESLint.Plugin>;
|
|
73
67
|
settings?: Record<string, unknown>;
|
|
74
68
|
rules: {
|
|
75
69
|
'style/jsx-sort-props': string;
|
|
76
70
|
'react/jsx-sort-props': string;
|
|
77
|
-
'vue-jsx-vapor/jsx-sort-props': 1 |
|
|
78
|
-
'vue-jsx-vapor/define-style': 1 |
|
|
71
|
+
'vue-jsx-vapor/jsx-sort-props': 1 | "off" | 2 | "warn" | "error" | [Linter.RuleSeverity, (JsxSortPropsSchema0 | undefined)?];
|
|
72
|
+
'vue-jsx-vapor/define-style': 1 | "off" | 2 | "warn" | "error" | [Linter.RuleSeverity, (DefineStyleSchema0 | undefined)?];
|
|
79
73
|
};
|
|
80
74
|
};
|
|
81
75
|
|
|
82
|
-
|
|
76
|
+
//#endregion
|
|
77
|
+
export { Rules, _default as default, plugins, ruleOptions as rules };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,41 +1,34 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import * as _typescript_eslint_utils_ts_eslint from '@typescript-eslint/utils/ts-eslint';
|
|
1
|
+
import { ESLint, Linter } from "eslint";
|
|
2
|
+
import { RuleListener, RuleModule } from "@typescript-eslint/utils/ts-eslint";
|
|
4
3
|
|
|
4
|
+
//#region src/rules/define-style/types.d.ts
|
|
5
5
|
interface DefineStyleSchema0 {
|
|
6
|
-
|
|
6
|
+
tabWidth?: number;
|
|
7
7
|
}
|
|
8
|
+
type DefineStyleRuleOptions = [DefineStyleSchema0?];
|
|
9
|
+
type MessageIds$1 = 'define-style' | 'define-style-syntax-error';
|
|
8
10
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
//#endregion
|
|
12
|
+
//#region src/rules/jsx-sort-props/types.d.ts
|
|
12
13
|
interface JsxSortPropsSchema0 {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
14
|
+
callbacksLast?: boolean;
|
|
15
|
+
shorthandFirst?: boolean;
|
|
16
|
+
shorthandLast?: boolean;
|
|
17
|
+
multiline?: 'ignore' | 'first' | 'last';
|
|
18
|
+
ignoreCase?: boolean;
|
|
19
|
+
noSortAlphabetically?: boolean;
|
|
20
|
+
reservedFirst?: string[] | boolean;
|
|
21
|
+
reservedLast?: string[];
|
|
22
|
+
locale?: string;
|
|
22
23
|
}
|
|
24
|
+
type JsxSortPropsRuleOptions = [JsxSortPropsSchema0?];
|
|
25
|
+
type MessageIds = 'listIsEmpty' | 'listReservedPropsFirst' | 'listReservedPropsLast' | 'listCallbacksLast' | 'listShorthandFirst' | 'listShorthandLast' | 'listMultilineFirst' | 'listMultilineLast' | 'sortPropsByAlpha';
|
|
23
26
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
| 'listIsEmpty'
|
|
27
|
-
| 'listReservedPropsFirst'
|
|
28
|
-
| 'listReservedPropsLast'
|
|
29
|
-
| 'listCallbacksLast'
|
|
30
|
-
| 'listShorthandFirst'
|
|
31
|
-
| 'listShorthandLast'
|
|
32
|
-
| 'listMultilineFirst'
|
|
33
|
-
| 'listMultilineLast'
|
|
34
|
-
| 'sortPropsByAlpha'
|
|
35
|
-
|
|
27
|
+
//#endregion
|
|
28
|
+
//#region src/rules/index.d.ts
|
|
36
29
|
declare const ruleOptions: {
|
|
37
|
-
'jsx-sort-props':
|
|
38
|
-
'define-style':
|
|
30
|
+
'jsx-sort-props': RuleModule<MessageIds, JsxSortPropsRuleOptions, unknown, RuleListener>;
|
|
31
|
+
'define-style': RuleModule<MessageIds$1, DefineStyleRuleOptions, unknown, RuleListener>;
|
|
39
32
|
};
|
|
40
33
|
interface RuleOptions {
|
|
41
34
|
'vue-jsx-vapor/jsx-sort-props': JsxSortPropsRuleOptions;
|
|
@@ -45,15 +38,16 @@ type Rules = Partial<{
|
|
|
45
38
|
[K in keyof RuleOptions]: Linter.RuleSeverity | [Linter.RuleSeverity, ...RuleOptions[K]];
|
|
46
39
|
}>;
|
|
47
40
|
|
|
41
|
+
//#endregion
|
|
42
|
+
//#region src/index.d.ts
|
|
48
43
|
declare const plugins: {
|
|
49
44
|
'vue-jsx-vapor': {
|
|
50
45
|
rules: {
|
|
51
|
-
'jsx-sort-props':
|
|
52
|
-
'define-style':
|
|
46
|
+
'jsx-sort-props': RuleModule<MessageIds, JsxSortPropsRuleOptions, unknown, RuleListener>;
|
|
47
|
+
'define-style': RuleModule<MessageIds$1, DefineStyleRuleOptions, unknown, RuleListener>;
|
|
53
48
|
};
|
|
54
49
|
};
|
|
55
50
|
};
|
|
56
|
-
|
|
57
51
|
declare const _default: ({ rules, ...options }?: Linter.Config<Rules>) => {
|
|
58
52
|
name: string;
|
|
59
53
|
files?: Array<string | string[]>;
|
|
@@ -65,18 +59,19 @@ declare const _default: ({ rules, ...options }?: Linter.Config<Rules>) => {
|
|
|
65
59
|
plugins: {
|
|
66
60
|
'vue-jsx-vapor': {
|
|
67
61
|
rules: {
|
|
68
|
-
'jsx-sort-props':
|
|
69
|
-
'define-style':
|
|
62
|
+
'jsx-sort-props': RuleModule<MessageIds, JsxSortPropsRuleOptions, unknown, RuleListener>;
|
|
63
|
+
'define-style': RuleModule<MessageIds$1, DefineStyleRuleOptions, unknown, RuleListener>;
|
|
70
64
|
};
|
|
71
65
|
};
|
|
72
|
-
} | Record<string,
|
|
66
|
+
} | Record<string, ESLint.Plugin>;
|
|
73
67
|
settings?: Record<string, unknown>;
|
|
74
68
|
rules: {
|
|
75
69
|
'style/jsx-sort-props': string;
|
|
76
70
|
'react/jsx-sort-props': string;
|
|
77
|
-
'vue-jsx-vapor/jsx-sort-props': 1 |
|
|
78
|
-
'vue-jsx-vapor/define-style': 1 |
|
|
71
|
+
'vue-jsx-vapor/jsx-sort-props': 1 | "off" | 2 | "warn" | "error" | [Linter.RuleSeverity, (JsxSortPropsSchema0 | undefined)?];
|
|
72
|
+
'vue-jsx-vapor/define-style': 1 | "off" | 2 | "warn" | "error" | [Linter.RuleSeverity, (DefineStyleSchema0 | undefined)?];
|
|
79
73
|
};
|
|
80
74
|
};
|
|
81
75
|
|
|
82
|
-
|
|
76
|
+
//#endregion
|
|
77
|
+
export { Rules, _default as default, plugins, ruleOptions as rules };
|