chore: raise error if no matching component found
This commit is contained in:
parent
833a88e439
commit
ad56cd95c8
1 changed files with 6 additions and 0 deletions
|
@ -39,6 +39,12 @@ export function createAstroNode(
|
|||
props,
|
||||
children,
|
||||
};
|
||||
} else if (isCapitalized(node.name)) {
|
||||
throw new Error(
|
||||
`[Markdoc] Unable to render ${JSON.stringify(
|
||||
node.name
|
||||
)}. Did you add this to the "components" prop on your <Content /> component?`
|
||||
);
|
||||
} else {
|
||||
return {
|
||||
tag: node.name,
|
||||
|
|
Loading…
Reference in a new issue