Skip to content

feat: use pglite to avoid requiring postgres when generating types#36

Open
MrAnderson323 wants to merge 7 commits into
seveibar:mainfrom
MrAnderson323:hyphaforge/issue-2-mqgv4j95
Open

feat: use pglite to avoid requiring postgres when generating types#36
MrAnderson323 wants to merge 7 commits into
seveibar:mainfrom
MrAnderson323:hyphaforge/issue-2-mqgv4j95

Conversation

@MrAnderson323

Copy link
Copy Markdown

When running bun run db:generate, users no longer need a running PostgreSQL instance. Instead, the type generation process spins up an in-process PGlite instance, applies the schema migrations, introspects the resulting schema, and generates types — all without any external dependencies.

This uses @electric-sql/pglite to run an ephemeral in-memory PostgreSQL-compatible database for schema introspection during type generation.


Closes #2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Use pglite so that postgres isn't required when generating types

1 participant