r/webdev • u/AHS12_96 • 46m ago
Resource I built a JavaScript diagram rendering engine that can handle thousands of nodes and edges
https://thoth-flow.ahs12.xyz/I've been working on ThothBlueprint, an open-source database diagramming tool, for over a year. As the project grew, rendering large database schemas became a serious performance challenge.
That led me to build Thoth Flow — a standalone JavaScript diagram rendering engine powered by WebGL2.
After integrating it into ThothBlueprint, I can now work with significantly larger diagrams. I tested it with 5,000 tables and 7,000 relationships, and it rendered smoothly.
This npm Package supports React, Vue, Svelte, Web Components, and plain JavaScript, with automatic Canvas 2D fallback.
If you're building database diagramming tools, node editors, workflow builders, or anything that needs to render large interactive diagrams, Thoth Flow might be useful.
I'd love for you to try it and share your feedback, especially on performance, API design, and potential improvements.
Links:
View all comments
0
u/ConcentrateLow5694 37m ago
Handling 5,000 tables and 7,000 relationships smoothly is genuinely impressive — that is usually the point where most diagram tools start to struggle. Keeping a React Flow-shaped API was a smart choice too, because it lowers the barrier for people who already know that pattern. I am curious how the Canvas 2D fallback performs at that same scale, since not every setup can rely on WebGL. Either way, this looks like a useful building block for anyone making database or workflow tools.