MCPcopy Index your code
hub / github.com/angular/angular / set

Method set

packages/compiler/src/render3/view/util.ts:156–166  ·  view source on GitHub ↗
(key: keyof T, value: o.Expression | null)

Source from the content-addressed store, hash-verified

154 values: {key: string; quoted: boolean; value: o.Expression}[] = [];
155
156 set(key: keyof T, value: o.Expression | null): void {
157 if (value) {
158 const existing = this.values.find((value) => value.key === key);
159
160 if (existing) {
161 existing.value = value;
162 } else {
163 this.values.push({key: key as string, value, quoted: false});
164 }
165 }
166 }
167
168 toLiteralMap(): o.LiteralMapExpr {
169 return o.literalMap(this.values);

Callers 15

compileInjectableFunction · 0.95
compileServiceFunction · 0.95
compileInjectorFunction · 0.95
compileNgModuleFunction · 0.95
createPipeDefinitionMapFunction · 0.95
compileDependencyFunction · 0.95

Calls 2

findMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected