@n8n/eslint-plugin-community-nodes 0.31.0 → 0.33.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/README.md +2 -1
- package/dist/plugin.d.ts +6 -0
- package/dist/plugin.d.ts.map +1 -1
- package/dist/plugin.js +2 -0
- package/dist/rules/ai-node-package-json.d.ts +3 -1
- package/dist/rules/ai-node-package-json.d.ts.map +1 -1
- package/dist/rules/cred-class-field-icon-missing.d.ts +3 -1
- package/dist/rules/cred-class-field-icon-missing.d.ts.map +1 -1
- package/dist/rules/cred-class-oauth2-naming.d.ts +3 -1
- package/dist/rules/cred-class-oauth2-naming.d.ts.map +1 -1
- package/dist/rules/credential-documentation-url.d.ts +3 -1
- package/dist/rules/credential-documentation-url.d.ts.map +1 -1
- package/dist/rules/credential-password-field.d.ts +3 -1
- package/dist/rules/credential-password-field.d.ts.map +1 -1
- package/dist/rules/credential-password-field.js +1 -2
- package/dist/rules/credential-test-required.d.ts +3 -1
- package/dist/rules/credential-test-required.d.ts.map +1 -1
- package/dist/rules/credential-unnecessary-password.d.ts +3 -1
- package/dist/rules/credential-unnecessary-password.d.ts.map +1 -1
- package/dist/rules/credential-unnecessary-password.js +1 -2
- package/dist/rules/icon-prefer-themed-variants.d.ts +3 -1
- package/dist/rules/icon-prefer-themed-variants.d.ts.map +1 -1
- package/dist/rules/icon-validation.d.ts +3 -1
- package/dist/rules/icon-validation.d.ts.map +1 -1
- package/dist/rules/icon-validation.js +5 -15
- package/dist/rules/index.d.ts +132 -43
- package/dist/rules/index.d.ts.map +1 -1
- package/dist/rules/index.js +2 -0
- package/dist/rules/missing-paired-item.d.ts +3 -1
- package/dist/rules/missing-paired-item.d.ts.map +1 -1
- package/dist/rules/n8n-object-validation.d.ts +3 -1
- package/dist/rules/n8n-object-validation.d.ts.map +1 -1
- package/dist/rules/no-builder-hint-leakage.d.ts +3 -1
- package/dist/rules/no-builder-hint-leakage.d.ts.map +1 -1
- package/dist/rules/no-credential-reuse.d.ts +3 -1
- package/dist/rules/no-credential-reuse.d.ts.map +1 -1
- package/dist/rules/no-credential-reuse.js +4 -6
- package/dist/rules/no-dangerous-functions.d.ts +3 -1
- package/dist/rules/no-dangerous-functions.d.ts.map +1 -1
- package/dist/rules/no-dead-files.d.ts +3 -1
- package/dist/rules/no-dead-files.d.ts.map +1 -1
- package/dist/rules/no-deprecated-workflow-functions.d.ts +3 -1
- package/dist/rules/no-deprecated-workflow-functions.d.ts.map +1 -1
- package/dist/rules/no-emoji-in-options.d.ts +3 -1
- package/dist/rules/no-emoji-in-options.d.ts.map +1 -1
- package/dist/rules/no-emoji-in-options.js +4 -4
- package/dist/rules/no-forbidden-lifecycle-scripts.d.ts +3 -1
- package/dist/rules/no-forbidden-lifecycle-scripts.d.ts.map +1 -1
- package/dist/rules/no-forbidden-lifecycle-scripts.js +1 -1
- package/dist/rules/no-hardcoded-secrets.d.ts +3 -1
- package/dist/rules/no-hardcoded-secrets.d.ts.map +1 -1
- package/dist/rules/no-http-request-with-manual-auth.d.ts +3 -1
- package/dist/rules/no-http-request-with-manual-auth.d.ts.map +1 -1
- package/dist/rules/no-overrides-field.d.ts +3 -1
- package/dist/rules/no-overrides-field.d.ts.map +1 -1
- package/dist/rules/no-restricted-globals.d.ts +3 -1
- package/dist/rules/no-restricted-globals.d.ts.map +1 -1
- package/dist/rules/no-restricted-imports.d.ts +3 -1
- package/dist/rules/no-restricted-imports.d.ts.map +1 -1
- package/dist/rules/no-runtime-dependencies.d.ts +3 -1
- package/dist/rules/no-runtime-dependencies.d.ts.map +1 -1
- package/dist/rules/no-silent-error-swallowing.d.ts +3 -1
- package/dist/rules/no-silent-error-swallowing.d.ts.map +1 -1
- package/dist/rules/no-template-placeholders.d.ts +3 -1
- package/dist/rules/no-template-placeholders.d.ts.map +1 -1
- package/dist/rules/no-unsafe-connection-type-cast.d.ts +5 -0
- package/dist/rules/no-unsafe-connection-type-cast.d.ts.map +1 -0
- package/dist/rules/no-unsafe-connection-type-cast.js +104 -0
- package/dist/rules/node-class-description-icon-missing.d.ts +3 -1
- package/dist/rules/node-class-description-icon-missing.d.ts.map +1 -1
- package/dist/rules/node-class-description-icon-missing.js +1 -2
- package/dist/rules/node-connection-type-literal.d.ts +3 -1
- package/dist/rules/node-connection-type-literal.d.ts.map +1 -1
- package/dist/rules/node-registration-complete.d.ts +3 -1
- package/dist/rules/node-registration-complete.d.ts.map +1 -1
- package/dist/rules/node-usable-as-tool.d.ts +3 -1
- package/dist/rules/node-usable-as-tool.d.ts.map +1 -1
- package/dist/rules/package-name-convention.d.ts +3 -1
- package/dist/rules/package-name-convention.d.ts.map +1 -1
- package/dist/rules/require-files-array.d.ts +3 -1
- package/dist/rules/require-files-array.d.ts.map +1 -1
- package/dist/rules/require-homepage.d.ts +3 -1
- package/dist/rules/require-homepage.d.ts.map +1 -1
- package/dist/rules/require-node-api-error.d.ts +3 -1
- package/dist/rules/require-node-api-error.d.ts.map +1 -1
- package/dist/rules/require-node-description-fields.d.ts +3 -1
- package/dist/rules/require-node-description-fields.d.ts.map +1 -1
- package/dist/rules/require-node-description-fields.js +1 -2
- package/dist/rules/require-version.d.ts +3 -1
- package/dist/rules/require-version.d.ts.map +1 -1
- package/dist/rules/resource-operation-pattern.d.ts +3 -1
- package/dist/rules/resource-operation-pattern.d.ts.map +1 -1
- package/dist/rules/resource-operation-pattern.js +3 -4
- package/dist/rules/trigger-node-conventions.d.ts +3 -1
- package/dist/rules/trigger-node-conventions.d.ts.map +1 -1
- package/dist/rules/valid-author.d.ts +3 -1
- package/dist/rules/valid-author.d.ts.map +1 -1
- package/dist/rules/valid-author.js +1 -1
- package/dist/rules/valid-credential-references.d.ts +3 -1
- package/dist/rules/valid-credential-references.d.ts.map +1 -1
- package/dist/rules/valid-credential-references.js +4 -6
- package/dist/rules/valid-description.d.ts +3 -1
- package/dist/rules/valid-description.d.ts.map +1 -1
- package/dist/rules/valid-peer-dependencies.d.ts +3 -1
- package/dist/rules/valid-peer-dependencies.d.ts.map +1 -1
- package/dist/rules/webhook-lifecycle-complete.d.ts +3 -1
- package/dist/rules/webhook-lifecycle-complete.d.ts.map +1 -1
- package/dist/utils/ast-utils.d.ts +6 -0
- package/dist/utils/ast-utils.d.ts.map +1 -1
- package/dist/utils/ast-utils.js +50 -0
- package/dist/utils/file-utils.d.ts.map +1 -1
- package/dist/utils/file-utils.js +1 -2
- package/dist/utils/rule-creator.d.ts +3 -1
- package/dist/utils/rule-creator.d.ts.map +1 -1
- package/docs/rules/icon-prefer-themed-variants.md +2 -2
- package/docs/rules/icon-validation.md +11 -11
- package/docs/rules/no-unsafe-connection-type-cast.md +58 -0
- package/eslint.config.mjs +2 -3
- package/package.json +8 -8
- package/src/plugin.ts +2 -0
- package/src/rules/credential-password-field.ts +1 -4
- package/src/rules/credential-unnecessary-password.ts +1 -4
- package/src/rules/icon-validation.test.ts +19 -21
- package/src/rules/icon-validation.ts +5 -20
- package/src/rules/index.ts +2 -0
- package/src/rules/no-credential-reuse.test.ts +54 -0
- package/src/rules/no-credential-reuse.ts +4 -8
- package/src/rules/no-emoji-in-options.test.ts +77 -0
- package/src/rules/no-emoji-in-options.ts +4 -4
- package/src/rules/no-forbidden-lifecycle-scripts.ts +1 -1
- package/src/rules/no-unsafe-connection-type-cast.test.ts +306 -0
- package/src/rules/no-unsafe-connection-type-cast.ts +125 -0
- package/src/rules/node-class-description-icon-missing.ts +1 -4
- package/src/rules/require-node-description-fields.ts +1 -4
- package/src/rules/resource-operation-pattern.ts +3 -6
- package/src/rules/valid-author.ts +1 -1
- package/src/rules/valid-credential-references.test.ts +75 -0
- package/src/rules/valid-credential-references.ts +4 -8
- package/src/utils/ast-utils.ts +67 -0
- package/src/utils/file-utils.ts +3 -6
- package/dist/plugin.js.map +0 -1
- package/dist/rules/ai-node-package-json.js.map +0 -1
- package/dist/rules/cred-class-field-icon-missing.js.map +0 -1
- package/dist/rules/cred-class-oauth2-naming.js.map +0 -1
- package/dist/rules/credential-documentation-url.js.map +0 -1
- package/dist/rules/credential-password-field.js.map +0 -1
- package/dist/rules/credential-test-required.js.map +0 -1
- package/dist/rules/credential-unnecessary-password.js.map +0 -1
- package/dist/rules/icon-prefer-themed-variants.js.map +0 -1
- package/dist/rules/icon-validation.js.map +0 -1
- package/dist/rules/index.js.map +0 -1
- package/dist/rules/missing-paired-item.js.map +0 -1
- package/dist/rules/n8n-object-validation.js.map +0 -1
- package/dist/rules/no-builder-hint-leakage.js.map +0 -1
- package/dist/rules/no-credential-reuse.js.map +0 -1
- package/dist/rules/no-dangerous-functions.js.map +0 -1
- package/dist/rules/no-dead-files.js.map +0 -1
- package/dist/rules/no-deprecated-workflow-functions.js.map +0 -1
- package/dist/rules/no-emoji-in-options.js.map +0 -1
- package/dist/rules/no-forbidden-lifecycle-scripts.js.map +0 -1
- package/dist/rules/no-hardcoded-secrets.js.map +0 -1
- package/dist/rules/no-http-request-with-manual-auth.js.map +0 -1
- package/dist/rules/no-overrides-field.js.map +0 -1
- package/dist/rules/no-restricted-globals.js.map +0 -1
- package/dist/rules/no-restricted-imports.js.map +0 -1
- package/dist/rules/no-runtime-dependencies.js.map +0 -1
- package/dist/rules/no-silent-error-swallowing.js.map +0 -1
- package/dist/rules/no-template-placeholders.js.map +0 -1
- package/dist/rules/node-class-description-icon-missing.js.map +0 -1
- package/dist/rules/node-connection-type-literal.js.map +0 -1
- package/dist/rules/node-registration-complete.js.map +0 -1
- package/dist/rules/node-usable-as-tool.js.map +0 -1
- package/dist/rules/package-name-convention.js.map +0 -1
- package/dist/rules/require-files-array.js.map +0 -1
- package/dist/rules/require-homepage.js.map +0 -1
- package/dist/rules/require-node-api-error.js.map +0 -1
- package/dist/rules/require-node-description-fields.js.map +0 -1
- package/dist/rules/require-version.js.map +0 -1
- package/dist/rules/resource-operation-pattern.js.map +0 -1
- package/dist/rules/trigger-node-conventions.js.map +0 -1
- package/dist/rules/valid-author.js.map +0 -1
- package/dist/rules/valid-credential-references.js.map +0 -1
- package/dist/rules/valid-description.js.map +0 -1
- package/dist/rules/valid-peer-dependencies.js.map +0 -1
- package/dist/rules/webhook-lifecycle-complete.js.map +0 -1
- package/dist/utils/ast-utils.js.map +0 -1
- package/dist/utils/constants.js.map +0 -1
- package/dist/utils/credential-fields.js.map +0 -1
- package/dist/utils/file-utils.js.map +0 -1
- package/dist/utils/index.js.map +0 -1
- package/dist/utils/rule-creator.js.map +0 -1
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { isNodeTypeClass, findClassProperty, findArrayLiteralProperty, extractCredentialNameFromArray, findPackageJson, readPackageJsonCredentials, isFileType, findSimilarStrings, createRule, } from '../utils/index.js';
|
|
1
|
+
import { isNodeTypeClass, findNodeDescriptionObject, findArrayLiteralProperty, extractCredentialNameFromArray, findPackageJson, readPackageJsonCredentials, isFileType, findSimilarStrings, createRule, } from '../utils/index.js';
|
|
3
2
|
export const NoCredentialReuseRule = createRule({
|
|
4
3
|
name: 'no-credential-reuse',
|
|
5
4
|
meta: {
|
|
@@ -38,12 +37,11 @@ export const NoCredentialReuseRule = createRule({
|
|
|
38
37
|
if (!isNodeTypeClass(node)) {
|
|
39
38
|
return;
|
|
40
39
|
}
|
|
41
|
-
const
|
|
42
|
-
if (!
|
|
43
|
-
descriptionProperty.value.type !== TSESTree.AST_NODE_TYPES.ObjectExpression) {
|
|
40
|
+
const description = findNodeDescriptionObject(node);
|
|
41
|
+
if (!description) {
|
|
44
42
|
return;
|
|
45
43
|
}
|
|
46
|
-
const credentialsArray = findArrayLiteralProperty(
|
|
44
|
+
const credentialsArray = findArrayLiteralProperty(description, 'credentials');
|
|
47
45
|
if (!credentialsArray) {
|
|
48
46
|
return;
|
|
49
47
|
}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoDangerousFunctionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"noChildProcess" | "noEval" | "noFunctionConstructor", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoDangerousFunctionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"noChildProcess" | "noEval" | "noFunctionConstructor", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-dangerous-functions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-dangerous-functions.d.ts","sourceRoot":"","sources":["../../src/rules/no-dangerous-functions.ts"],"names":[],"mappings":"AAgCA,eAAO,MAAM,wBAAwB,
|
|
1
|
+
{"version":3,"file":"no-dangerous-functions.d.ts","sourceRoot":"","sources":["../../src/rules/no-dangerous-functions.ts"],"names":[],"mappings":"AAgCA,eAAO,MAAM,wBAAwB;;CA0HnC,CAAC"}
|
|
@@ -3,5 +3,7 @@
|
|
|
3
3
|
* test-artifact file that should not ship with a community node.
|
|
4
4
|
*/
|
|
5
5
|
export declare function isDeadFileName(fileName: string): boolean;
|
|
6
|
-
export declare const NoDeadFilesRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"deadFileFound", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
6
|
+
export declare const NoDeadFilesRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"deadFileFound", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
7
|
+
name: string;
|
|
8
|
+
};
|
|
7
9
|
//# sourceMappingURL=no-dead-files.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-dead-files.d.ts","sourceRoot":"","sources":["../../src/rules/no-dead-files.ts"],"names":[],"mappings":"AAmBA;;;GAGG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAExD;AAED,eAAO,MAAM,eAAe,
|
|
1
|
+
{"version":3,"file":"no-dead-files.d.ts","sourceRoot":"","sources":["../../src/rules/no-dead-files.ts"],"names":[],"mappings":"AAmBA;;;GAGG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAExD;AAED,eAAO,MAAM,eAAe;;CA2C1B,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoDeprecatedWorkflowFunctionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"deprecatedFunction" | "deprecatedRequestFunction" | "deprecatedType" | "deprecatedWithoutReplacement" | "suggestReplaceFunction" | "suggestReplaceType", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoDeprecatedWorkflowFunctionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"deprecatedFunction" | "deprecatedRequestFunction" | "deprecatedType" | "deprecatedWithoutReplacement" | "suggestReplaceFunction" | "suggestReplaceType", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-deprecated-workflow-functions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-deprecated-workflow-functions.d.ts","sourceRoot":"","sources":["../../src/rules/no-deprecated-workflow-functions.ts"],"names":[],"mappings":"AAyBA,eAAO,MAAM,iCAAiC,
|
|
1
|
+
{"version":3,"file":"no-deprecated-workflow-functions.d.ts","sourceRoot":"","sources":["../../src/rules/no-deprecated-workflow-functions.ts"],"names":[],"mappings":"AAyBA,eAAO,MAAM,iCAAiC;;CA6I5C,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoEmojiInOptionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"emojiInOption", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoEmojiInOptionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"emojiInOption", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-emoji-in-options.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-emoji-in-options.d.ts","sourceRoot":"","sources":["../../src/rules/no-emoji-in-options.ts"],"names":[],"mappings":"AAoBA,eAAO,MAAM,oBAAoB
|
|
1
|
+
{"version":3,"file":"no-emoji-in-options.d.ts","sourceRoot":"","sources":["../../src/rules/no-emoji-in-options.ts"],"names":[],"mappings":"AAoBA,eAAO,MAAM,oBAAoB;;CAoF/B,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { AST_NODE_TYPES } from '@typescript-eslint/utils';
|
|
2
|
-
import { isNodeTypeClass,
|
|
2
|
+
import { isNodeTypeClass, findNodeDescriptionObject, getStringLiteralValue, isFileType, createRule, } from '../utils/index.js';
|
|
3
3
|
/**
|
|
4
4
|
* Matches emoji characters: pictographs (😀, 🚀, ✉️, etc.) and regional
|
|
5
5
|
* indicator symbols that compose flag emoji (🇺🇸).
|
|
@@ -74,11 +74,11 @@ export const NoEmojiInOptionsRule = createRule({
|
|
|
74
74
|
if (!isNodeTypeClass(node)) {
|
|
75
75
|
return;
|
|
76
76
|
}
|
|
77
|
-
const
|
|
78
|
-
if (!
|
|
77
|
+
const description = findNodeDescriptionObject(node);
|
|
78
|
+
if (!description) {
|
|
79
79
|
return;
|
|
80
80
|
}
|
|
81
|
-
traverse(
|
|
81
|
+
traverse(description);
|
|
82
82
|
},
|
|
83
83
|
};
|
|
84
84
|
},
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoForbiddenLifecycleScriptsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"forbiddenScript", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoForbiddenLifecycleScriptsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"forbiddenScript", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-forbidden-lifecycle-scripts.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-forbidden-lifecycle-scripts.d.ts","sourceRoot":"","sources":["../../src/rules/no-forbidden-lifecycle-scripts.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,+BAA+B,
|
|
1
|
+
{"version":3,"file":"no-forbidden-lifecycle-scripts.d.ts","sourceRoot":"","sources":["../../src/rules/no-forbidden-lifecycle-scripts.ts"],"names":[],"mappings":"AAeA,eAAO,MAAM,+BAA+B;;CAqD1C,CAAC"}
|
|
@@ -33,7 +33,7 @@ export const NoForbiddenLifecycleScriptsRule = createRule({
|
|
|
33
33
|
return;
|
|
34
34
|
}
|
|
35
35
|
const scriptsProp = findJsonProperty(node, 'scripts');
|
|
36
|
-
if (
|
|
36
|
+
if (scriptsProp?.value.type !== AST_NODE_TYPES.ObjectExpression) {
|
|
37
37
|
return;
|
|
38
38
|
}
|
|
39
39
|
for (const property of scriptsProp.value.properties) {
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoHardcodedSecretsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"hardcodedSecret", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoHardcodedSecretsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"hardcodedSecret", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-hardcoded-secrets.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-hardcoded-secrets.d.ts","sourceRoot":"","sources":["../../src/rules/no-hardcoded-secrets.ts"],"names":[],"mappings":"AAkGA,eAAO,MAAM,sBAAsB,
|
|
1
|
+
{"version":3,"file":"no-hardcoded-secrets.d.ts","sourceRoot":"","sources":["../../src/rules/no-hardcoded-secrets.ts"],"names":[],"mappings":"AAkGA,eAAO,MAAM,sBAAsB;;CA8DjC,CAAC"}
|
|
@@ -15,5 +15,7 @@
|
|
|
15
15
|
* Known false positive: a function that fetches credentials for a non-HTTP purpose
|
|
16
16
|
* and also makes an unauthenticated request. Use eslint-disable to suppress.
|
|
17
17
|
*/
|
|
18
|
-
export declare const NoHttpRequestWithManualAuthRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"useHttpRequestWithAuthentication", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
18
|
+
export declare const NoHttpRequestWithManualAuthRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"useHttpRequestWithAuthentication", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
19
|
+
name: string;
|
|
20
|
+
};
|
|
19
21
|
//# sourceMappingURL=no-http-request-with-manual-auth.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-http-request-with-manual-auth.d.ts","sourceRoot":"","sources":["../../src/rules/no-http-request-with-manual-auth.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAWH,eAAO,MAAM,+BAA+B,
|
|
1
|
+
{"version":3,"file":"no-http-request-with-manual-auth.d.ts","sourceRoot":"","sources":["../../src/rules/no-http-request-with-manual-auth.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAWH,eAAO,MAAM,+BAA+B;;CAkD1C,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoOverridesFieldRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"overridesForbidden", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoOverridesFieldRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"overridesForbidden", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-overrides-field.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-overrides-field.d.ts","sourceRoot":"","sources":["../../src/rules/no-overrides-field.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,oBAAoB
|
|
1
|
+
{"version":3,"file":"no-overrides-field.d.ts","sourceRoot":"","sources":["../../src/rules/no-overrides-field.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,oBAAoB;;CAwC/B,CAAC"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
import type { TSESLint } from '@typescript-eslint/utils';
|
|
2
|
-
export declare const NoRestrictedGlobalsRule: TSESLint.RuleModule<"restrictedGlobal" | "restrictedGlobalWithHint", [], unknown, TSESLint.RuleListener
|
|
2
|
+
export declare const NoRestrictedGlobalsRule: TSESLint.RuleModule<"restrictedGlobal" | "restrictedGlobalWithHint", [], unknown, TSESLint.RuleListener> & {
|
|
3
|
+
name: string;
|
|
4
|
+
};
|
|
3
5
|
//# sourceMappingURL=no-restricted-globals.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-restricted-globals.d.ts","sourceRoot":"","sources":["../../src/rules/no-restricted-globals.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAwBzD,eAAO,MAAM,uBAAuB,
|
|
1
|
+
{"version":3,"file":"no-restricted-globals.d.ts","sourceRoot":"","sources":["../../src/rules/no-restricted-globals.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAwBzD,eAAO,MAAM,uBAAuB;;CAiElC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoRestrictedImportsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"restrictedDynamicImport" | "restrictedImport" | "restrictedRequire", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoRestrictedImportsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"restrictedDynamicImport" | "restrictedImport" | "restrictedRequire", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-restricted-imports.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-restricted-imports.d.ts","sourceRoot":"","sources":["../../src/rules/no-restricted-imports.ts"],"names":[],"mappings":"AAuCA,eAAO,MAAM,uBAAuB,
|
|
1
|
+
{"version":3,"file":"no-restricted-imports.d.ts","sourceRoot":"","sources":["../../src/rules/no-restricted-imports.ts"],"names":[],"mappings":"AAuCA,eAAO,MAAM,uBAAuB;;CAkElC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoRuntimeDependenciesRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"runtimeDependenciesForbidden", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoRuntimeDependenciesRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"runtimeDependenciesForbidden", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-runtime-dependencies.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-runtime-dependencies.d.ts","sourceRoot":"","sources":["../../src/rules/no-runtime-dependencies.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,yBAAyB,
|
|
1
|
+
{"version":3,"file":"no-runtime-dependencies.d.ts","sourceRoot":"","sources":["../../src/rules/no-runtime-dependencies.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,yBAAyB;;CA4CpC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoSilentErrorSwallowingRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"emptyCatch" | "silentReturn", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoSilentErrorSwallowingRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"emptyCatch" | "silentReturn", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-silent-error-swallowing.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-silent-error-swallowing.d.ts","sourceRoot":"","sources":["../../src/rules/no-silent-error-swallowing.ts"],"names":[],"mappings":"AA6CA,eAAO,MAAM,2BAA2B,
|
|
1
|
+
{"version":3,"file":"no-silent-error-swallowing.d.ts","sourceRoot":"","sources":["../../src/rules/no-silent-error-swallowing.ts"],"names":[],"mappings":"AA6CA,eAAO,MAAM,2BAA2B;;CAiFtC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NoTemplatePlaceholdersRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"unresolvedPlaceholder", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NoTemplatePlaceholdersRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"unresolvedPlaceholder", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=no-template-placeholders.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"no-template-placeholders.d.ts","sourceRoot":"","sources":["../../src/rules/no-template-placeholders.ts"],"names":[],"mappings":"AAsBA,eAAO,MAAM,0BAA0B
|
|
1
|
+
{"version":3,"file":"no-template-placeholders.d.ts","sourceRoot":"","sources":["../../src/rules/no-template-placeholders.ts"],"names":[],"mappings":"AAsBA,eAAO,MAAM,0BAA0B;;CA+CrC,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { TSESLint } from '@typescript-eslint/utils';
|
|
2
|
+
export declare const NoUnsafeConnectionTypeCastRule: TSESLint.RuleModule<"erasingCast" | "removeCast", [], unknown, TSESLint.RuleListener> & {
|
|
3
|
+
name: string;
|
|
4
|
+
};
|
|
5
|
+
//# sourceMappingURL=no-unsafe-connection-type-cast.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-unsafe-connection-type-cast.d.ts","sourceRoot":"","sources":["../../src/rules/no-unsafe-connection-type-cast.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAY,MAAM,0BAA0B,CAAC;AA0DnE,eAAO,MAAM,8BAA8B;;CAiEzC,CAAC"}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { AST_NODE_TYPES } from '@typescript-eslint/utils';
|
|
2
|
+
import { isNodeTypeClass, findClassProperty, findObjectProperty, findJsonProperty, createRule, } from '../utils/index.js';
|
|
3
|
+
const ERASING_KEYWORDS = {
|
|
4
|
+
[AST_NODE_TYPES.TSNeverKeyword]: 'never',
|
|
5
|
+
[AST_NODE_TYPES.TSAnyKeyword]: 'any',
|
|
6
|
+
[AST_NODE_TYPES.TSUnknownKeyword]: 'unknown',
|
|
7
|
+
};
|
|
8
|
+
function isCast(node) {
|
|
9
|
+
return (node.type === AST_NODE_TYPES.TSAsExpression || node.type === AST_NODE_TYPES.TSTypeAssertion);
|
|
10
|
+
}
|
|
11
|
+
function isWrapper(node) {
|
|
12
|
+
return isCast(node) || node.type === AST_NODE_TYPES.TSSatisfiesExpression;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Walks a wrapper chain such as `x as unknown as string[]` or
|
|
16
|
+
* `x as never satisfies string[]`, outermost first. `satisfies` is traversed
|
|
17
|
+
* but never collected: it checks the value instead of erasing its type, so it
|
|
18
|
+
* can hide a cast without being one.
|
|
19
|
+
*/
|
|
20
|
+
function collectCasts(node) {
|
|
21
|
+
const casts = [];
|
|
22
|
+
let current = node;
|
|
23
|
+
while (isWrapper(current)) {
|
|
24
|
+
if (isCast(current))
|
|
25
|
+
casts.push(current);
|
|
26
|
+
current = current.expression;
|
|
27
|
+
}
|
|
28
|
+
return casts;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Removes the cast syntax itself and nothing else, so every other part of the
|
|
32
|
+
* chain survives: a `satisfies` at any depth, and the expression's own text.
|
|
33
|
+
*/
|
|
34
|
+
function removeCastSyntax(fixer, cast) {
|
|
35
|
+
return cast.type === AST_NODE_TYPES.TSTypeAssertion
|
|
36
|
+
? // `<never>expr`: drop the leading `<never>`
|
|
37
|
+
fixer.removeRange([cast.range[0], cast.expression.range[0]])
|
|
38
|
+
: // `expr as never`: drop the trailing ` as never`
|
|
39
|
+
fixer.removeRange([cast.expression.range[1], cast.range[1]]);
|
|
40
|
+
}
|
|
41
|
+
export const NoUnsafeConnectionTypeCastRule = createRule({
|
|
42
|
+
name: 'no-unsafe-connection-type-cast',
|
|
43
|
+
meta: {
|
|
44
|
+
type: 'problem',
|
|
45
|
+
docs: {
|
|
46
|
+
description: 'Disallow type-erasing casts (`as never`, `as any`, `as unknown`) on node description `inputs`/`outputs`',
|
|
47
|
+
},
|
|
48
|
+
messages: {
|
|
49
|
+
erasingCast: 'Remove the `as {{typeName}}` cast on "{{property}}". It disables type checking, so a malformed connection declaration passes both TypeScript and lint.',
|
|
50
|
+
removeCast: 'Remove the cast',
|
|
51
|
+
},
|
|
52
|
+
hasSuggestions: true,
|
|
53
|
+
schema: [],
|
|
54
|
+
},
|
|
55
|
+
defaultOptions: [],
|
|
56
|
+
create(context) {
|
|
57
|
+
function checkProperty(value, property) {
|
|
58
|
+
const casts = collectCasts(value);
|
|
59
|
+
const [outermost] = casts;
|
|
60
|
+
if (!outermost)
|
|
61
|
+
return;
|
|
62
|
+
// A chain is unsafe if any link erases the type, e.g. the `unknown`
|
|
63
|
+
// in `as unknown as string[]` is what defeats the checker.
|
|
64
|
+
const erasing = casts.find((cast) => ERASING_KEYWORDS[cast.typeAnnotation.type]);
|
|
65
|
+
if (!erasing)
|
|
66
|
+
return;
|
|
67
|
+
// Report the outermost cast rather than the whole property value, so a
|
|
68
|
+
// `satisfies` wrapped around it stays put when the suggestion is applied.
|
|
69
|
+
context.report({
|
|
70
|
+
node: outermost,
|
|
71
|
+
messageId: 'erasingCast',
|
|
72
|
+
data: {
|
|
73
|
+
typeName: ERASING_KEYWORDS[erasing.typeAnnotation.type],
|
|
74
|
+
property,
|
|
75
|
+
},
|
|
76
|
+
suggest: [
|
|
77
|
+
{
|
|
78
|
+
messageId: 'removeCast',
|
|
79
|
+
fix: (fixer) => casts.map((cast) => removeCastSyntax(fixer, cast)),
|
|
80
|
+
},
|
|
81
|
+
],
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
return {
|
|
85
|
+
ClassDeclaration(node) {
|
|
86
|
+
if (!isNodeTypeClass(node))
|
|
87
|
+
return;
|
|
88
|
+
const descriptionProperty = findClassProperty(node, 'description');
|
|
89
|
+
if (!descriptionProperty)
|
|
90
|
+
return;
|
|
91
|
+
const descriptionValue = descriptionProperty.value;
|
|
92
|
+
if (descriptionValue?.type !== AST_NODE_TYPES.ObjectExpression)
|
|
93
|
+
return;
|
|
94
|
+
for (const prop of ['inputs', 'outputs']) {
|
|
95
|
+
const property = findObjectProperty(descriptionValue, prop) ?? findJsonProperty(descriptionValue, prop);
|
|
96
|
+
if (!property)
|
|
97
|
+
continue;
|
|
98
|
+
checkProperty(property.value, prop);
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
};
|
|
102
|
+
},
|
|
103
|
+
});
|
|
104
|
+
//# sourceMappingURL=no-unsafe-connection-type-cast.js.map
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
/** @deprecated Use `require-node-description-fields` instead. */
|
|
2
|
-
export declare const NodeClassDescriptionIconMissingRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"addPlaceholder" | "missingIcon", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
2
|
+
export declare const NodeClassDescriptionIconMissingRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"addPlaceholder" | "missingIcon", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
3
|
+
name: string;
|
|
4
|
+
};
|
|
3
5
|
//# sourceMappingURL=node-class-description-icon-missing.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node-class-description-icon-missing.d.ts","sourceRoot":"","sources":["../../src/rules/node-class-description-icon-missing.ts"],"names":[],"mappings":"AAUA,iEAAiE;AACjE,eAAO,MAAM,mCAAmC,
|
|
1
|
+
{"version":3,"file":"node-class-description-icon-missing.d.ts","sourceRoot":"","sources":["../../src/rules/node-class-description-icon-missing.ts"],"names":[],"mappings":"AAUA,iEAAiE;AACjE,eAAO,MAAM,mCAAmC;;CA8D9C,CAAC"}
|
|
@@ -30,8 +30,7 @@ export const NodeClassDescriptionIconMissingRule = createRule({
|
|
|
30
30
|
return;
|
|
31
31
|
}
|
|
32
32
|
const descriptionProperty = findClassProperty(node, 'description');
|
|
33
|
-
if (
|
|
34
|
-
descriptionProperty.value.type !== TSESTree.AST_NODE_TYPES.ObjectExpression) {
|
|
33
|
+
if (descriptionProperty?.value?.type !== TSESTree.AST_NODE_TYPES.ObjectExpression) {
|
|
35
34
|
return;
|
|
36
35
|
}
|
|
37
36
|
const descriptionValue = descriptionProperty.value;
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NodeConnectionTypeLiteralRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"stringLiteralInInputs" | "stringLiteralInOutputs" | "unknownStringLiteralInInputs" | "unknownStringLiteralInOutputs", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NodeConnectionTypeLiteralRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"stringLiteralInInputs" | "stringLiteralInOutputs" | "unknownStringLiteralInInputs" | "unknownStringLiteralInOutputs", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=node-connection-type-literal.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node-connection-type-literal.d.ts","sourceRoot":"","sources":["../../src/rules/node-connection-type-literal.ts"],"names":[],"mappings":"AAuBA,eAAO,MAAM,6BAA6B,
|
|
1
|
+
{"version":3,"file":"node-connection-type-literal.d.ts","sourceRoot":"","sources":["../../src/rules/node-connection-type-literal.ts"],"names":[],"mappings":"AAuBA,eAAO,MAAM,6BAA6B;;CA0ExC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NodeRegistrationCompleteRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"nodeNotRegistered", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NodeRegistrationCompleteRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"nodeNotRegistered", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=node-registration-complete.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node-registration-complete.d.ts","sourceRoot":"","sources":["../../src/rules/node-registration-complete.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,4BAA4B,
|
|
1
|
+
{"version":3,"file":"node-registration-complete.d.ts","sourceRoot":"","sources":["../../src/rules/node-registration-complete.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,4BAA4B;;CAkEvC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const NodeUsableAsToolRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"aiOnlyUsableAsTool" | "missingUsableAsTool" | "triggerUsableAsTool", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const NodeUsableAsToolRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"aiOnlyUsableAsTool" | "missingUsableAsTool" | "triggerUsableAsTool", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=node-usable-as-tool.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node-usable-as-tool.d.ts","sourceRoot":"","sources":["../../src/rules/node-usable-as-tool.ts"],"names":[],"mappings":"AAcA,eAAO,MAAM,oBAAoB
|
|
1
|
+
{"version":3,"file":"node-usable-as-tool.d.ts","sourceRoot":"","sources":["../../src/rules/node-usable-as-tool.ts"],"names":[],"mappings":"AAcA,eAAO,MAAM,oBAAoB;;CA2G/B,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const PackageNameConventionRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"defaultPlaceholderName" | "invalidPackageName" | "missingName" | "renameTo", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const PackageNameConventionRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"defaultPlaceholderName" | "invalidPackageName" | "missingName" | "renameTo", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=package-name-convention.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"package-name-convention.d.ts","sourceRoot":"","sources":["../../src/rules/package-name-convention.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,yBAAyB
|
|
1
|
+
{"version":3,"file":"package-name-convention.d.ts","sourceRoot":"","sources":["../../src/rules/package-name-convention.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,yBAAyB;;CAwFpC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const RequireFilesArrayRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"filesEmpty" | "filesMissing", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const RequireFilesArrayRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"filesEmpty" | "filesMissing", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=require-files-array.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"require-files-array.d.ts","sourceRoot":"","sources":["../../src/rules/require-files-array.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,qBAAqB,
|
|
1
|
+
{"version":3,"file":"require-files-array.d.ts","sourceRoot":"","sources":["../../src/rules/require-files-array.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,qBAAqB;;CA4ChC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const RequireHomepageRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"homepageInvalid" | "homepageMissing", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const RequireHomepageRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"homepageInvalid" | "homepageMissing", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=require-homepage.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"require-homepage.d.ts","sourceRoot":"","sources":["../../src/rules/require-homepage.ts"],"names":[],"mappings":"AAcA,eAAO,MAAM,mBAAmB,
|
|
1
|
+
{"version":3,"file":"require-homepage.d.ts","sourceRoot":"","sources":["../../src/rules/require-homepage.ts"],"names":[],"mappings":"AAcA,eAAO,MAAM,mBAAmB;;CA4C9B,CAAC"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
import { TSESLint } from '@typescript-eslint/utils';
|
|
2
|
-
export declare const RequireNodeApiErrorRule: TSESLint.RuleModule<"useNodeApiError" | "useNodeApiErrorInsteadOfGeneric", [], unknown, TSESLint.RuleListener
|
|
2
|
+
export declare const RequireNodeApiErrorRule: TSESLint.RuleModule<"useNodeApiError" | "useNodeApiErrorInsteadOfGeneric", [], unknown, TSESLint.RuleListener> & {
|
|
3
|
+
name: string;
|
|
4
|
+
};
|
|
3
5
|
//# sourceMappingURL=require-node-api-error.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"require-node-api-error.d.ts","sourceRoot":"","sources":["../../src/rules/require-node-api-error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,QAAQ,EAAiB,MAAM,0BAA0B,CAAC;AA2BnF,eAAO,MAAM,uBAAuB
|
|
1
|
+
{"version":3,"file":"require-node-api-error.d.ts","sourceRoot":"","sources":["../../src/rules/require-node-api-error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,QAAQ,EAAiB,MAAM,0BAA0B,CAAC;AA2BnF,eAAO,MAAM,uBAAuB;;CA+DlC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const RequireNodeDescriptionFieldsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"missingField" | "missingFields", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const RequireNodeDescriptionFieldsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"missingField" | "missingFields", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=require-node-description-fields.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"require-node-description-fields.d.ts","sourceRoot":"","sources":["../../src/rules/require-node-description-fields.ts"],"names":[],"mappings":"AAiBA,eAAO,MAAM,gCAAgC,
|
|
1
|
+
{"version":3,"file":"require-node-description-fields.d.ts","sourceRoot":"","sources":["../../src/rules/require-node-description-fields.ts"],"names":[],"mappings":"AAiBA,eAAO,MAAM,gCAAgC;;CAwD3C,CAAC"}
|
|
@@ -28,8 +28,7 @@ export const RequireNodeDescriptionFieldsRule = createRule({
|
|
|
28
28
|
return;
|
|
29
29
|
}
|
|
30
30
|
const descriptionProperty = findClassProperty(node, 'description');
|
|
31
|
-
if (
|
|
32
|
-
descriptionProperty.value.type !== TSESTree.AST_NODE_TYPES.ObjectExpression) {
|
|
31
|
+
if (descriptionProperty?.value?.type !== TSESTree.AST_NODE_TYPES.ObjectExpression) {
|
|
33
32
|
return;
|
|
34
33
|
}
|
|
35
34
|
const descriptionValue = descriptionProperty.value;
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const RequireVersionRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"invalidVersion" | "missingVersion", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const RequireVersionRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"invalidVersion" | "missingVersion", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=require-version.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"require-version.d.ts","sourceRoot":"","sources":["../../src/rules/require-version.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,kBAAkB,
|
|
1
|
+
{"version":3,"file":"require-version.d.ts","sourceRoot":"","sources":["../../src/rules/require-version.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,kBAAkB;;CAoD7B,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const ResourceOperationPatternRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"tooManyOperationsWithoutResources", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const ResourceOperationPatternRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"tooManyOperationsWithoutResources", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=resource-operation-pattern.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resource-operation-pattern.d.ts","sourceRoot":"","sources":["../../src/rules/resource-operation-pattern.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,4BAA4B,
|
|
1
|
+
{"version":3,"file":"resource-operation-pattern.d.ts","sourceRoot":"","sources":["../../src/rules/resource-operation-pattern.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,4BAA4B;;CAwFvC,CAAC"}
|
|
@@ -18,12 +18,11 @@ export const ResourceOperationPatternRule = createRule({
|
|
|
18
18
|
return {};
|
|
19
19
|
}
|
|
20
20
|
const analyzeNodeDescription = (descriptionValue) => {
|
|
21
|
-
if (
|
|
21
|
+
if (descriptionValue?.type !== AST_NODE_TYPES.ObjectExpression) {
|
|
22
22
|
return;
|
|
23
23
|
}
|
|
24
24
|
const propertiesProperty = findObjectProperty(descriptionValue, 'properties');
|
|
25
|
-
if (
|
|
26
|
-
propertiesProperty.value.type !== AST_NODE_TYPES.ArrayExpression) {
|
|
25
|
+
if (propertiesProperty?.value?.type !== AST_NODE_TYPES.ArrayExpression) {
|
|
27
26
|
return;
|
|
28
27
|
}
|
|
29
28
|
const propertiesArray = propertiesProperty.value;
|
|
@@ -31,7 +30,7 @@ export const ResourceOperationPatternRule = createRule({
|
|
|
31
30
|
let operationCount = 0;
|
|
32
31
|
let operationNode = null;
|
|
33
32
|
for (const property of propertiesArray.elements) {
|
|
34
|
-
if (
|
|
33
|
+
if (property?.type !== AST_NODE_TYPES.ObjectExpression) {
|
|
35
34
|
continue;
|
|
36
35
|
}
|
|
37
36
|
const nameProperty = findObjectProperty(property, 'name');
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const TriggerNodeConventionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"displayNameMissingTrigger" | "inputsNotEmpty" | "nameMissingSuffix", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const TriggerNodeConventionsRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"displayNameMissingTrigger" | "inputsNotEmpty" | "nameMissingSuffix", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=trigger-node-conventions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"trigger-node-conventions.d.ts","sourceRoot":"","sources":["../../src/rules/trigger-node-conventions.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,0BAA0B,
|
|
1
|
+
{"version":3,"file":"trigger-node-conventions.d.ts","sourceRoot":"","sources":["../../src/rules/trigger-node-conventions.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,0BAA0B;;CAgFrC,CAAC"}
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const ValidAuthorRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"authorEmailMissing" | "authorMissing" | "authorNameMissing", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const ValidAuthorRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"authorEmailMissing" | "authorMissing" | "authorNameMissing", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=valid-author.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"valid-author.d.ts","sourceRoot":"","sources":["../../src/rules/valid-author.ts"],"names":[],"mappings":"AA+BA,eAAO,MAAM,eAAe
|
|
1
|
+
{"version":3,"file":"valid-author.d.ts","sourceRoot":"","sources":["../../src/rules/valid-author.ts"],"names":[],"mappings":"AA+BA,eAAO,MAAM,eAAe;;CAoE1B,CAAC"}
|
|
@@ -18,7 +18,7 @@ function parsePersonString(value) {
|
|
|
18
18
|
return { name, email };
|
|
19
19
|
}
|
|
20
20
|
function isNonEmptyStringLiteral(node) {
|
|
21
|
-
if (
|
|
21
|
+
if (node?.value.type !== AST_NODE_TYPES.Literal) {
|
|
22
22
|
return false;
|
|
23
23
|
}
|
|
24
24
|
const { value } = node.value;
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export declare const ValidCredentialReferencesRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"credentialNotFound" | "didYouMean", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener
|
|
1
|
+
export declare const ValidCredentialReferencesRule: import("@typescript-eslint/utils/ts-eslint").RuleModule<"credentialNotFound" | "didYouMean", [], unknown, import("@typescript-eslint/utils/ts-eslint").RuleListener> & {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
2
4
|
//# sourceMappingURL=valid-credential-references.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"valid-credential-references.d.ts","sourceRoot":"","sources":["../../src/rules/valid-credential-references.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"valid-credential-references.d.ts","sourceRoot":"","sources":["../../src/rules/valid-credential-references.ts"],"names":[],"mappings":"AAcA,eAAO,MAAM,6BAA6B;;CAsFxC,CAAC"}
|