MCPcopy
hub / github.com/angular/angular / throwMultipleComponentError

Function throwMultipleComponentError

packages/core/src/render3/errors.ts:51–62  ·  view source on GitHub ↗
(
  tNode: TNode,
  first: Type<unknown> | AbstractType<unknown>,
  second: Type<unknown> | AbstractType<unknown>,
)

Source from the content-addressed store, hash-verified

49
50/** Called when there are multiple component selectors that match a given node */
51export function throwMultipleComponentError(
52 tNode: TNode,
53 first: Type<unknown> | AbstractType<unknown>,
54 second: Type<unknown> | AbstractType<unknown>,
55): never {
56 throw new RuntimeError(
57 RuntimeErrorCode.MULTIPLE_COMPONENTS_MATCH,
58 `Multiple components match node with tagname ${tNode.value}: ` +
59 `${stringifyForError(first)} and ` +
60 `${stringifyForError(second)}`,
61 );
62}
63
64/** Throws an ExpressionChangedAfterChecked error if checkNoChanges mode is on. */
65export function throwErrorIfNoChangesMode(

Callers 1

findDirectiveDefMatchesFunction · 0.90

Calls 1

stringifyForErrorFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…