🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more →

@angular-eslint/utils

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@angular-eslint/utils - npm Package Compare versions

Comparing version

to
19.4.1-alpha.1

@@ -124,2 +124,3 @@ import type { TSESTree } from '@typescript-eslint/utils';

export declare function getPropertyDefinitionName({ computed, key, }: TSESTree.PropertyDefinition): string;
export declare const getDecoratorProperties: (decorator: TSESTree.Decorator) => TSESTree.Property[];
export declare const getDecoratorProperty: (decorator: TSESTree.Decorator, name: string) => TSESTree.Property | undefined;

@@ -126,0 +127,0 @@ export declare const getDecoratorPropertyValue: (decorator: TSESTree.Decorator, name: string) => TSESTree.Property["value"] | undefined;

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getLifecycleInterfaceByMethodName = exports.getMethodName = exports.getDeclaredMethods = exports.getDecoratorPropertyValue = exports.getDecoratorProperty = exports.isAngularInnerClassDecorator = exports.isAngularClassDecorator = exports.isAngularLifecycleMethod = exports.isAngularLifecycleInterface = exports.ANGULAR_LIFECYCLE_METHODS = exports.ANGULAR_LIFECYCLE_INTERFACES = exports.getDecoratorName = exports.getDecoratorArgument = exports.getAngularClassDecorator = exports.getDecorator = exports.getClassName = exports.getDeclaredAngularLifecycleMethods = exports.getDeclaredAngularLifecycleInterfaces = exports.getPipeDecorator = exports.ANGULAR_CLASS_DECORATOR_MAPPER = exports.ANGULAR_CLASS_DECORATORS = exports.ANGULAR_INNER_CLASS_DECORATORS = exports.ANGULAR_CLASS_DECORATOR_LIFECYCLE_METHOD_MAPPER = exports.angularLifecycleMethodsOrdered = exports.angularLifecycleMethodKeys = exports.angularLifecycleInterfaceKeys = exports.angularInnerClassDecoratorKeys = exports.angularClassDecoratorKeys = exports.OPTION_STYLE_KEBAB_CASE = exports.OPTION_STYLE_CAMEL_CASE = exports.AngularLifecycleMethods = exports.AngularLifecycleInterfaces = exports.AngularInnerClassDecorators = exports.AngularClassDecorators = void 0;
exports.getLifecycleInterfaceByMethodName = exports.getMethodName = exports.getDeclaredMethods = exports.getDecoratorPropertyValue = exports.getDecoratorProperty = exports.getDecoratorProperties = exports.isAngularInnerClassDecorator = exports.isAngularClassDecorator = exports.isAngularLifecycleMethod = exports.isAngularLifecycleInterface = exports.ANGULAR_LIFECYCLE_METHODS = exports.ANGULAR_LIFECYCLE_INTERFACES = exports.getDecoratorName = exports.getDecoratorArgument = exports.getAngularClassDecorator = exports.getDecorator = exports.getClassName = exports.getDeclaredAngularLifecycleMethods = exports.getDeclaredAngularLifecycleInterfaces = exports.getPipeDecorator = exports.ANGULAR_CLASS_DECORATOR_MAPPER = exports.ANGULAR_CLASS_DECORATORS = exports.ANGULAR_INNER_CLASS_DECORATORS = exports.ANGULAR_CLASS_DECORATOR_LIFECYCLE_METHOD_MAPPER = exports.angularLifecycleMethodsOrdered = exports.angularLifecycleMethodKeys = exports.angularLifecycleInterfaceKeys = exports.angularInnerClassDecoratorKeys = exports.angularClassDecoratorKeys = exports.OPTION_STYLE_KEBAB_CASE = exports.OPTION_STYLE_CAMEL_CASE = exports.AngularLifecycleMethods = exports.AngularLifecycleInterfaces = exports.AngularInnerClassDecorators = exports.AngularClassDecorators = void 0;
exports.getCorrespondentImportClause = getCorrespondentImportClause;

@@ -337,6 +337,8 @@ exports.getImportDeclarations = getImportDeclarations;

}
const getDecoratorProperties = (decorator) => {
return (0, exports.getDecoratorArgument)(decorator)?.properties.filter(isProperty) ?? [];
};
exports.getDecoratorProperties = getDecoratorProperties;
const getDecoratorProperty = (decorator, name) => {
return (0, exports.getDecoratorArgument)(decorator)
?.properties.filter(isProperty)
.find(({ key }) => utils_1.ASTUtils.isIdentifier(key) && key.name === name);
return (0, exports.getDecoratorProperties)(decorator).find(({ key }) => utils_1.ASTUtils.isIdentifier(key) && key.name === name);
};

@@ -343,0 +345,0 @@ exports.getDecoratorProperty = getDecoratorProperty;

@@ -5,2 +5,3 @@ export { toHumanReadableText, arrayify, isNotNullOrUndefined, toPattern, kebabToCamelCase, withoutBracketsAndWhitespaces, capitalize, } from './utils';

export * as ASTUtils from './eslint-plugin/ast-utils';
export * as CommentUtils from './eslint-plugin/comment-utils';
export * as RuleFixes from './eslint-plugin/rule-fixes';

@@ -7,0 +8,0 @@ export * as Selectors from './eslint-plugin/selectors';

@@ -36,3 +36,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.getTemplateParserServices = exports.ensureTemplateParser = exports.SelectorUtils = exports.Selectors = exports.RuleFixes = exports.ASTUtils = exports.getNativeEventNames = exports.getAriaAttributeKeys = exports.capitalize = exports.withoutBracketsAndWhitespaces = exports.kebabToCamelCase = exports.toPattern = exports.isNotNullOrUndefined = exports.arrayify = exports.toHumanReadableText = void 0;
exports.getTemplateParserServices = exports.ensureTemplateParser = exports.SelectorUtils = exports.Selectors = exports.RuleFixes = exports.CommentUtils = exports.ASTUtils = exports.getNativeEventNames = exports.getAriaAttributeKeys = exports.capitalize = exports.withoutBracketsAndWhitespaces = exports.kebabToCamelCase = exports.toPattern = exports.isNotNullOrUndefined = exports.arrayify = exports.toHumanReadableText = void 0;
var utils_1 = require("./utils");

@@ -51,2 +51,3 @@ Object.defineProperty(exports, "toHumanReadableText", { enumerable: true, get: function () { return utils_1.toHumanReadableText; } });

exports.ASTUtils = __importStar(require("./eslint-plugin/ast-utils"));
exports.CommentUtils = __importStar(require("./eslint-plugin/comment-utils"));
exports.RuleFixes = __importStar(require("./eslint-plugin/rule-fixes"));

@@ -53,0 +54,0 @@ exports.Selectors = __importStar(require("./eslint-plugin/selectors"));

{
"name": "@angular-eslint/utils",
"version": "19.4.1-alpha.0",
"version": "19.4.1-alpha.1",
"license": "MIT",

@@ -25,3 +25,3 @@ "main": "dist/index.js",

"dependencies": {
"@angular-eslint/bundled-angular-compiler": "19.4.1-alpha.0"
"@angular-eslint/bundled-angular-compiler": "19.4.1-alpha.1"
},

@@ -28,0 +28,0 @@ "nx": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet