drizzle-team / drizzle-team/drizzle-orm

[FEATURE]: Implementing Standard Schema as a way to declare db schema

Open
#4,303 4 comments 1 reaction 0 assignees View on GitHub
drizzle/arktype drizzle/typebox drizzle/valibot drizzle/zod enhancement
Dominant language
TypeScript
Stars
35.8k
Forks
1.6k
Avg merge
2d 7h
Merged PRs (30d)
4

Description

### Feature hasn't been suggested before.

- [x] I have verified this feature I'm about to request hasn't been suggested before.

### Describe the enhancement you want to request

A different way of creating db schema could be from [Standard Schema](https://standardschema.dev/)

Although to my knowledge there is no easy or efficient way to get a standard _schema_ from a validator, It would be awesome to be able to generate a table schema from a standard schema instead of the (currently possible) opposite.

Maybe some kind of "collaboration" with Standard Schema would be profitable for everyone.

The main reason would be to be able to reuse the standard schema in the front end without importing the whole db schema and parts of Drizzle into the client code.

It is what is partly suggested in #941

Possibly related issues :
https://github.com/standard-schema/standard-schema/issues/71
https://github.com/standard-schema/standard-schema/issues/7

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.