chore(warnings): add error codes to documentation site

This commit is contained in:
Christopher Möller
2022-04-28 16:27:19 +02:00
parent 922005e236
commit 9331ccc544
7 changed files with 10 additions and 12 deletions
+1 -3
View File
@@ -39,9 +39,7 @@ export function useMarkerSymbol(type: MarkerType) {
const symbolExists = MarkerSymbols.hasOwnProperty(type);
if (!symbolExists) {
console.warn(
`[React Flow]: marker type "${type}" doesn't exist. Help: https://reactflow.dev/docs/guides/troubleshooting`
);
console.warn(`[React Flow]: Marker type "${type}" doesn't exist. Help: https://reactflow.dev/error-decoder#900`);
return () => null;
}
+2 -2
View File
@@ -107,14 +107,14 @@ const EdgeRenderer = (props: EdgeRendererProps) => {
if (!sourceHandle) {
console.warn(
`[React Flow]: couldn't create edge for source handle id: ${edge.sourceHandle}; edge id: ${edge.id}. Help: https://reactflow.dev/docs/guides/troubleshooting`
`[React Flow]: Couldn't create edge for source handle id: ${edge.sourceHandle}; edge id: ${edge.id}. Help: https://reactflow.dev/error-decoder#800`
);
return null;
}
if (!targetHandle) {
console.warn(
`[React Flow]: couldn't create edge for target handle id: ${edge.targetHandle}; edge id: ${edge.id}. Help: https://reactflow.dev/docs/guides/troubleshooting`
`[React Flow]: Couldn't create edge for target handle id: ${edge.targetHandle}; edge id: ${edge.id}. Help: https://reactflow.dev/error-decoder#800`
);
return null;
}