Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
igalklebanov
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
6 ms
·
1.
▲
by
igalklebanov
5mo ago
here's a good write up on the type-safety advantages https://github.com/thetutlage/meta/discussions/8
2.
▲
by
igalklebanov
5mo ago
As far as query building goes, `kysely` is more in-depth, type-safe, expressive, 1:1 and doesn't require importing as many things. `kysely-ctl` doesn't generate migrations for you, and `kysely` not being an ORM, doesn't provi
3.
▲
Kysely (the type-safe SQL query builder for TypeScript) v0.29 is out btw
(github.com)
3 points
by
igalklebanov
5mo ago
|
5 comments
4.
▲
by
igalklebanov
5mo ago
Hey DISCLAIMER: I'm co-leading the org/project. We recently broke 6M downloads per week on NPM, and became 3rd after `drizzle-orm` and `@prisma/client`. If you haven't tried it yet, it's a query builder, not an ORM.
5.
▲
by
igalklebanov
1y ago
can you share your personal documentation story? what did you not find? what was painful?
6.
▲
by
igalklebanov
1y ago
it depends on the database. the major ones support savepoints. postgres included. https://www.postgresql.org/docs/current/sql-savepoint.html https://dev.mysql.com/doc/refman/8.4/en&#
7.
▲
Kysely (the type-safe SQL query builder for TypeScript) 0.28 is out
(github.com)
2 points
by
igalklebanov
1y ago
|
5 comments
8.
▲
by
igalklebanov
1y ago
thoughts? requests? issues? <3
9.
▲
by
igalklebanov
3y ago
JOOQ is cool! What do you mean by "better type safety"? Kysely's ecosystem has 2 codegen libraries: kysely-codegen introspects the database directly. prisma-kysely generates types based on Prisma schemas.
10.
▲
by
igalklebanov
3y ago
Looks cool! Kysely was inspired by Knex, but took a more predictable route instead of providing generic APIs that produce different SQL for different dialects. We believe that dialect "lock-in" should never be a real concern becau
11.
▲
by
igalklebanov
3y ago
postgres.js is dope! I'm maintaining a Kysely community dialect for it. https://github.com/igalklebanov/kysely-postgres-js
12.
▲
by
igalklebanov
3y ago
<3 from Kysely. Would love to have a discussion about your use case in our discord. We're constantly thinking about improving that part of our API as it's at the heart of many things.
13.
▲
by
igalklebanov
3y ago
Huge shoutout to our community, bloggers and youtubers! https://github.com/kysely-org/awesome-kysely
14.
▲
by
igalklebanov
3y ago
<3 from Kysely. kysely-codegen is dope!
15.
▲
by
igalklebanov
3y ago
I'd suggest you try them both, and pick what you like better or what feels safer to bet on for your project. I know some of our users use both, zapatos for codegen and kysely for querying.
16.
▲
by
igalklebanov
3y ago
It was also requested in prisma-kysely recently. Might be a good idea to check kysely-codegen's issues section and open an issue if it wasn't requested yet.
17.
▲
by
igalklebanov
3y ago
Hey :wave: Igal from Kysely here (I did not create it, Sami did). Our site is a constant WIP. We've recently revamped "Getting Started" and added a lot of examples. If you can't find something there, check the API docs s
18.
▲
by
igalklebanov
3y ago
We love Knex, and are inspired by it. Sadly its not type-safe and reaching type-safety would require a rewrite. We care a lot about our TypeScript compilation performance and Developer eXperience in general. v0.25 introduced internal change
19.
▲
by
igalklebanov
3y ago
Kysely has community projects that offer Database interface auto-generation. kysely-codegen can introspect all core dialects. prisma-kysely can generate straight from Prisma schemas. We recommend using these in production apps. You could ve
20.
▲
by
igalklebanov
3y ago
> which supports automatic type-safety for complex joins, CTEs, subselects etc. I evaluated Kysely as well but found the sql feature set coverage of ts-sql-query better at the time. Kysely also provides "automatic type-safety for co
21.
▲
by
igalklebanov
3y ago
<3 from Kysely. kysely-codegen is really dope!
22.
▲
by
igalklebanov
3y ago
<3 from Kysely. prisma-kysely is dope!
23.
▲
by
igalklebanov
3y ago
<3 from Kysely.
24.
▲
by
igalklebanov
3y ago
Have you read this recipe? https://kysely.dev/docs/recipes/relations
25.
▲
by
igalklebanov
3y ago
Kysely is not an ORM, its a query builder with strong emphasis on type-safety and 1:1* mapping ("What You See Is What You Get") to SQL. Projects writing raw SQL eventually end up implementing their own query building functionality
26.
▲
by
igalklebanov
3y ago
> Personally I like both projects, as I hope I made clear in the OP <3 You did, but it generally sounded like Kysely doesn't have a bunch of things, when in fact it does. A more balanced comment would've suggested both proje
27.
▲
by
igalklebanov
3y ago
Kysely is just a query builder. Its human nature to always look for ORMs.
28.
▲
by
igalklebanov
3y ago
> It's also - in terms of performance - super fast Kysely is also super fast. Your bottleneck will always be database requests. If you're chasing every milli, why node.js? > the extra database drivers being core and develope
29.
▲
by
igalklebanov
3y ago
You can use D1 with Kysely (the typesafe sql query builder) via the kysely-d1 3rd party dialect. https://github.com/kysely-org/kysely https://github.com/aidenwallis/kysely-d1