chore(warnings): format warning logs, add troubleshooting page

This commit is contained in:
Christopher Möller
2022-04-26 16:33:54 +02:00
parent 3e91fc18e3
commit 922005e236
8 changed files with 30 additions and 11 deletions
+3 -1
View File
@@ -71,7 +71,9 @@ const NodeRenderer = (props: NodeRendererProps) => {
const nodeType = node.type || 'default';
if (!props.nodeTypes[nodeType]) {
console.warn(`Node type "${nodeType}" not found. Using fallback type "default".`);
console.warn(
`[React Flow]: Node type "${nodeType}" not found. Using fallback type "default". Help: https://reactflow.dev/docs/guides/troubleshooting`
);
}
const NodeComponent = (props.nodeTypes[nodeType] || props.nodeTypes.default) as ComponentType<WrapNodeProps>;