Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: drizzle orm integration #5894

Merged
merged 4 commits into from
Feb 27, 2024
Merged

feat: drizzle orm integration #5894

merged 4 commits into from
Feb 27, 2024

Conversation

LazyClicks
Copy link
Contributor

@LazyClicks LazyClicks commented Feb 26, 2024

Overview

What is it?

  • [x ] Feature / enhancement
  • Bug
  • [ x ] Docs / tests / types / typos

Description

Drizzle Orm integration with qwik, based this integration on the existing prisma integration

Use cases and why

    1. One use case
    1. Another use case

Checklist:

  • [ x ] My code follows the developer guidelines of this project
  • [ x ] I have performed a self-review of my own code
  • [x ] I have made corresponding changes to the documentation
  • Added new tests to cover the fix / functionality

Copy link

netlify bot commented Feb 26, 2024

👷 Deploy request for qwik-insights pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit d1f56bb

@LazyClicks LazyClicks changed the title Feat: drizzle orm integration feat: drizzle orm integration Feb 26, 2024
@gioboa gioboa added COMP: docs Improvements or additions to documentation COMP: starters labels Feb 26, 2024
"dependencies": {
"drizzle-orm": "^0.29.1",
"@neondatabase/serverless": "^0.8.1",
"pg": "^8.11.3"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it not possible to install a lighter DB by default? Perhaps there's something builtin without any deps?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If not, how about sqlite? That would allow it to work out-of-the-box

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i had thought drizzle doesnt support schemas with sqlite as their docs says but it seems it does, just not multiple schemas? im still confused by that, checking with their support, but i did switch to better-sqlite3 as it is the documented one in their docs

@wmertens
Copy link
Member

Can you also run pnpm fmt?

@LazyClicks
Copy link
Contributor Author

Can you also run pnpm fmt?

i wasnt able to install the pnpm dependencies, i keep getting wrong node version errors, i tried following the contribution guide by installing the rust thingy and running pnpm i but that diddnt work either, tried changing my own version of node and it didnt work as well

@LazyClicks
Copy link
Contributor Author

Can you also run pnpm fmt?

my test included using my implementation in a new qwik project
i also ran pnpm fmt that comes with qwik projects inside them before pasting inside the integrations files as i couldnt install with pnpm i

Copy link
Member

@wmertens wmertens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@wmertens wmertens enabled auto-merge (squash) February 27, 2024 20:35
@wmertens wmertens merged commit 2b61b00 into QwikDev:main Feb 27, 2024
22 checks passed
Copy link
Member

@gioboa gioboa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @LazyClicks 😉

@LazyClicks LazyClicks deleted the feat--drizzleORM-integration branch February 28, 2024 17:18
@LazyClicks
Copy link
Contributor Author

@gioboa @wmertens for some reason the db folder inside the drizzle directory didnt get pushed into the commit? idk if its due to it being empty, but without it the drizzle migrate command which is required for creating the database wont run
is there anything i can do to modify it here or should i make a new PR?

@LazyClicks
Copy link
Contributor Author

also the integration is not visible in the integrations docs, did i mess something up?
its accessible by link tho?
https://qwik.dev/docs/integrations/drizzle/

@wmertens
Copy link
Member

wmertens commented Mar 4, 2024

Empty dirs don't exist in git so they need a .empty file in them (or whatever).

As for the integration TOC, not sure :-/

You can make a new PR to fix these.

@renovate renovate bot mentioned this pull request May 10, 2024
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
COMP: docs Improvements or additions to documentation COMP: starters
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants