MCPcopy Create free account
hub / github.com/angular/angular / getSafePropertyAccessString

Function getSafePropertyAccessString

packages/compiler/src/render3/util.ts:48–51  ·  view source on GitHub ↗
(accessor: string, name: string)

Source from the content-addressed store, hash-verified

46}
47
48export function getSafePropertyAccessString(accessor: string, name: string): string {
49 const escapedName = escapeIdentifier(name, false);
50 return escapedName !== name ? `${accessor}[${escapedName}]` : `${accessor}.${name}`;
51}
52
53export function jitOnlyGuardedExpression(expr: o.Expression): o.Expression {
54 return guardedExpression('ngJitMode', expr);

Callers 2

extractHostBindingsFunction · 0.90
extractHostBindingsFunction · 0.90

Calls 1

escapeIdentifierFunction · 0.90

Tested by

no test coverage detected