$ show drawdb-io/drawdb
drawDB is a free, open-source, client-side web application for designing relational database schemas and generating SQL. It provides an interactive ER diagram editor with support for multiple database dialects (MySQL, PostgreSQL, SQLite, MariaDB, MSSQL, Oracle), import/export in SQL, DBML, JSON, Mermaid, and Markdown, and features like auto-arrange, auto-connect foreign keys, schema validation, migration generation, and versioning via GitHub Gists. The architecture is a React single-page application (Vite + Tailwind CSS + Semi UI) with state managed through custom React Contexts and hooks, persistence via IndexedDB (Dexie), and an optional cloud backend through an extension system. It is primarily an application, with no data research or ML components.
The LLM identified 4 files worth highlighting for reuse:
A generic, reusable drag-and-drop list component built with @dnd-kit. It supports sorting, dragging handles, and customizable rendering. Can be extracted and used in any React project requiring reorderable lists.
A reusable wrapper around Monaco Editor with theme support, copy-to-clipboard button, and DBML language configuration. Provides a clean API for embedding a code editor in any React application.
A well-structured SQL generation engine that produces CREATE/ALTER statements for multiple database dialects (MySQL, PostgreSQL, SQLite, etc.) from a unified diagram model. Demonstrates clean separation of concerns and can be reused in other schema-to-SQL tools.
A comprehensive, hand-maintained data type registry for all supported databases. Each type includes validation rules, size/precision flags, increment support, and compatibility lists. This is a valuable reference data asset that could be reused in any database tooling project.