MCPcopy Create free account
hub / github.com/angular/components / _hasModifier

Method _hasModifier

tools/tslint-rules/memberNamingRule.ts:107–112  ·  view source on GitHub ↗

Checks if a node has a specific modifier.

(
    node: ts.ClassElement | ts.ParameterDeclaration,
    targetKind: ts.SyntaxKind,
  )

Source from the content-addressed store, hash-verified

105
106 /** Checks if a node has a specific modifier. */
107 private _hasModifier(
108 node: ts.ClassElement | ts.ParameterDeclaration,
109 targetKind: ts.SyntaxKind,
110 ): boolean {
111 return ts.canHaveModifiers(node) && !!node.modifiers?.some(({kind}) => kind === targetKind);
112 }
113}

Callers 2

visitClassDeclarationMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected