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

Function directiveDefs

packages/core/src/render3/jit/directive.ts:242–258  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

240 let cachedDirectiveDefs: DirectiveDefList | null = null;
241 let cachedPipeDefs: PipeDefList | null = null;
242 const directiveDefs = () => {
243 if (ngDevMode) {
244 for (const rawDep of imports) {
245 verifyStandaloneImport(rawDep, type);
246 }
247 }
248
249 if (!isComponent(type)) {
250 return [];
251 }
252
253 const scope = depsTracker.getStandaloneComponentScope(type, imports);
254
255 return [...scope.compilation.directives]
256 .map((p) => (getComponentDef(p) || getDirectiveDef(p))!)
257 .filter((d) => d !== null);
258 };
259
260 const pipeDefs = () => {
261 if (ngDevMode) {

Callers

nothing calls this directly

Calls 7

verifyStandaloneImportFunction · 0.90
isComponentFunction · 0.90
getComponentDefFunction · 0.90
getDirectiveDefFunction · 0.90
mapMethod · 0.80
filterMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…