# They Finally Fixed Prisma

## Метаданные

- **Канал:** Josh tried coding
- **YouTube:** https://www.youtube.com/watch?v=JuAauKOj1Kk
- **Дата:** 26.11.2025
- **Длительность:** 16:35
- **Просмотры:** 18,871
- **Источник:** https://ekstraktznaniy.ru/video/49187

## Описание

They finally fixed my least favorite things about Prisma. The Prisma Rust engine makes it so TypeScript people can hardly contribute, makes Prisma literally undeployable (💀) to Cloudflare workers and is just.. bloat? The 7.0 update changes that 👀

-- links
Release article: https://www.prisma.io/blog/announcing-prisma-orm-7-0-0

-- my links
twitter: https://x.com/joshtriedcoding
github: https://github.com/joschan21

## Транскрипт

### Segment 1 (00:00 - 05:00) []

The number one ORM that I recommend to all beginners that get into web and TypeScript is Prisma ORM. Now, for personal projects, I haven't used Prisma in over a year, but the brand new Prisma 7 that they just released actually makes me excited to try Prisma again. I'm really excited to go through this with you because Prisma was the first ORM that I've ever used in my development career over the last 3 years and it's about time to be honest that it gets an update. So announcing Prisma 7 today we're thrilled to announce the latest release of Prisma ORM and Prisma Postgress because if you didn't know Prisma has their own planet scale or neon competitor they actually provide a hosted database themselves. Why? We're going to get to that later. Over the past year we focused on making it simpler and faster to build applications with Prisma. No matter what tools you use or where you deploy with exceptional developer experience at the core. This is unfortunately a very empty statement. I want the meat. I want the numbers. This is like we're putting effort into Prisma without saying anything, which is really disappointing. They did a much better job here on their Twitter actually saying what's new in Prisma 7. For example, the rust free Prisma client as the new default whereas before in all previous Prisma versions, they used Rust which made it really hard to deploy on Cloudflare workers or even Versel. 90% smaller bundle size and three times faster queries. That sounds really impressive and direct connections to Prisma Postgress and Prisma Postgress is going to be an interesting point later because from a business perspective what they're doing here providing their own database is really clever. Prisma 7 is not just a new major version. It's establishing the foundation for how developers build the future. That's meaningless man. Let's get into the actual details here. We've removed Rust to make your bundles smaller and faster while shipping native ESM as a default. That's really cool because what that does is deployment to for example Versel or Cloudflare workers that the Rust engine was literally too big for like 10 or 12 megabytes. It did not actually work. Now works because by default it doesn't use Rust anymore. So this is a really huge change. The second one, they have a dedicated config file with programmatic control over what environment variables get used for full control over your projects. This is very similar syntax- wise if we take a look at this to drizzle or m surprisingly, right? So they kind of they got inspired by Drizzle, you know, they provide their schemas here, migrations, the data source. It looks very similar, probably fair enough because what Drizzle did here actually works surprisingly well in standard TypeScript. And lastly, one of the coolest things in this new update, the new Prisma Studio has more functionality with full editing control over your data all from a brand new interface. And they put this kind of GIF here. This looks really, really clean, arguably even cleaner now than the Drizzle Studio. Right? So Drizzle and Prisma are some of the two most interesting ORMs that we talked about and Prisma 7 is their try to convince you to use Prisma and not Drizzle. Now did they succeed? Is it actually worth going for Prisma 7 over for example Drizzle? Well, let's see. Designed for the future. In December 2024, we published our vision for the future of Prisma ORM along with the steps we plan to take to achieve it. In this article, this Prisma manifesto that they published back then was unfortunately one of the most empty articles I have read. This manifesto outlines Prisma's vision for the future, addressing key challenges, whatever that means. Setting clear priorities and empowering collaboration to build a better experience for our community. This just sounds like AI generated because there's no actual content in here. So while the Prisma team does get into some numbers here like the releases or pull requests merge, what I found most interesting is here at the end the guiding principles to guide Prisma as they move forward. These principles will shape how we work and deliver value to our community. Developer first, focus on quality and so on. I don't know man, I can't take this seriously because this is a really empty statement. So I think much more important than this weird vision for the future of Prisma, let's see what they actually shipped and what's better. This manifesto was not just a set of ideas. It was a clear commitment to how we want Prisma ORM to evolve. That's not really true. It's more of a broad vision, but it didn't imply most of the changes that we see today in Prisma 7. We also launched our own managed Postgress offering Prisma Postgress. From a business perspective, this is super clever because what many of you might not know is that Prisma is actually a venturefunded company, right? So if you check Crunchb right here, Prisma at Prisma, we're building the data access layer for modern

### Segment 2 (05:00 - 10:00) [5:00]

applications in San Francisco with a growth score that's pretty rapidly declining. This will be important in a bit. Prisma raised about 40 million for their series B. So they are an established venturebacked company. Turns out making an OM is cool and all and people like you, but it's probably really hard to make money off of it. So you need a hosted database to actually make money from. So this is clever and if it works well, good on them, man. But enough of Prisma Postgress. This is not what this article is about. It's about Prisma 7 and what's new. By far the biggest item on what's new in 7 is moving away from Rust. When we launched Prisma 6, we promised better performance, more flexibility, and a better type safety. We knew there was work to be done, and to get there, we needed to make some drastic changes. This really, really hits the nail on the head because one of the best competitors out there to Prisma is catching up fast. And I suspect this is one of the biggest reasons why they made this update and prioritize the things that they did. It might be because another OM called Drizzle popped up in the scene that many of you probably already know. And Drizzle is gaining a lot of attention, like 2. 6 million downloads. If we use download as a proxy or as an idea for adoption, it's getting close to Prisma, man. Drizzle was a team of three people. Now it's two as far as I know. And they are not venturebacked whatsoever and already get 2. 6 million downloads. The Prisma client in comparison again assuming that we're using downloads as kind of a idea for adoption it's at about 5 million with a 40 million series B you can see the kind of problem here right if a twoperson team is catching up so fast to A or M some things need to change and in a way they have probably Drizzle to thank for this update because a lot of what's in here is inspired by Drizzle one of the core changes We announced we were migrating the Prisma client away from Rust and rebuilding it in Typescript. The Rust engine was problematic. This might have seemed like a strange move to some as Rust's main premise is that it's fast and performant. But that is only half the story in our case. Because while it's true that Rust is really fast and performant, turns out if you make a TypeScript orM using Rust has two very, very big problems. And one of these problems John from Prisma explained really well on Reddit. Does anyone use Prisma outside of the JS ecosystem? If 90% of the users are using JS or TypeScript, having Rust as a backend is an odd choice because what was also new to me is the origin story of Prisma. It did not start as an OM. That would be probably really hard to get venture back in the first place. The Rust engine is the way it is due to the path of the company. It went from GraphQL to Prisma 1 and then to Prisma OM. Originally, Prisma was a GraphQL server in your infra written in Scola that eventually evolved into the Rust engine. And people, myself included, had big problems with the Rust engine because you cannot deploy it to Cloudflare Works. It would actually not let you because it's too big. And strategically, the biggest problem with the Rust engine is that it's very opposed to the idea of serverless. Serverless being limited size functions, lightweight being executed over and over in isolated V8 in the case of node. There are other ORMs again spanning the bridge to Drizzle here that do this natively that just work in serverless where Prisma did not and the market especially around Versel serverless is so huge that Drizzle did very well with their approach. Even the founder in 2023 did some foreshadowing that Drizzle became so good that other OM will have to get better. And he's right. Prisma actually has to adapt because otherwise Drizzle the innovator I will call it in the space will actually exceed them, right? And as a venture-backed company, you don't want that to happen to you. Drizzle went public on January 3rd, had completely humble beginnings, and then things went wild. Drizzle went off the charts through the roof and I can't wait to tell you more about it. The whole growth comes down to a single point in time. We've had a completely regular start slowly building our user base and then we've been DAXed. So there was actually a piece of content put out. The Prisma killer has arrived on YouTube, right? And that's how Drizzle became famous. Then other people, myself included, made videos about Drizzle and that really got them forward. Of course, Prisma took notice and now has really, really good reasons to adapt their API and design choices to what Drizzle does. So, that's number one. There's this widely adopted very fast growing OM that does some things better than you do, especially around serverless. That's a good reason to rip out the Rust engine. The other reason, a side effect of the client being in Rust is that we were limiting who can contribute to the OM, right? If 90% of the users are in

### Segment 3 (10:00 - 15:00) [10:00]

Typescript land, people probably don't know a lot of Rust. If you didn't have strong Rust experience, it was far more difficult to make any meaningful contribution. On the technical side, the communication layer between Rust and the JavaScript runtime is much slower than doing things in plain JavaScript. Plus, it creates additional dependencies on runtime. So, ripping out that Rust engine becomes the obvious choice, right? It's huge like 10 or 12 megabytes makes deploying on some platforms impossible like Cloudflare workers and it stops people from contributing right three really good reasons for Prisma to finally rip it out and in my head I hope that Drizzle has inspired this movement. So starting with Prisma 7 we no longer need to worry about runtime specific quirks or infrastructure providers like Cloudflare workers limiting the size of the deployed application. Great. The results of ripping out Rust are pretty obvious. A 90% smaller bundle output. This sounds really, really cool. Three times faster query execution. So, it seems like that Rust JavaScript connection was really slowing things down. Significantly lower CPU and memory utilization and simpler deployments for Versel Edge, which is kind of deprecated, but I guess people still use it because it's just Cloudflare workers under the hood and Cloudflare workers. And we have the benchmarks to prove it. Let's check out the performance of Prisma 7. And here we go. No binary overhead. The dependency on native Rust binaries is eliminated. That simplifies deployment and reduce potential complexity issues. Up to 3. 4 times faster queries by removing cross language serialization. Yeah, that was what I guessed. And a 90% smaller bundle size from 14 megaby to 1. 6 megaby. Now 1. 6 6 megaby still seems pretty sizable, but coming from 14 megabytes, man, that's GTA 6 kind of That's crazy. So, in a lot of ways, it feels like the ORMs are converging, right? Prisma removes Rust and introduces a config file. Drizzle introduces a query API that looks just like Prisma. It feels like the ORMs are coming very, very close together and both are building quite the similar thing. In fact, Prisma has even written a separate blog article about this. And for us as developers, that's really good. So, they've taken the feedback regarding how they handle generated artifacts and made it better and more universally compatible. We covered this some time ago, but we historically generated the client in your project's node modules. At the time, this made sense as we wanted to make working with a generated client feel like any other library. What you used to do is, let me pull up a terminal here. Every time you made changes to the schema. prisma, you'd need to run npx prisma generate and it would code gen, right? That's how the typescript integration worked. And every time you need to stop your server, generate the types and then you could move on and optionally also push into your database. But as time has progressed, we found that this impacts developer workflow significantly. If the client needs to be updated, any app specific processes need to be stopped first before regenerating the types, which was annoying and also very preventable. Drizzle did this a lot easier because it's just TypeScript. Drizzle didn't have this. So instead, we default to generating the types and Prisma client in your project source code. So your existing dev and build tools see it as part of your app. Now, if you make changes to your models and run Prisma generate tools and file watchers can react to these changes and keep your dev workflow running. I'm going to skip on this whole config section here. I don't think it's too interesting. We saw the config file earlier. It looks like this where basically in standard TypeScript now you define schema migrations and your data source. It's pretty basic. It's very similar to what Drizzle does. And I'm actually really happy that they decided to implement it in an API that looks really similar to Drizzle because if you use one now it's really easy to use the other as well. Faster and fewer types. And I think types are more of a vanity metric because rarely from my experience to projects get so complex that typing actually slows down your IDE. Right? You would have to get really complex in Typescript to get to that point. Especially with a somewhat normal computer. Rarely is Typescript a reason for your IT to be slow. It's still cool to nerd out about this though. So for the new seven release together with David, the creator of Archype, they measured some typing benchmarks in the new Prisma. Like 89% fewer types to evaluate a schema and 45% fewer types for query evaluation. And for a full type check, I assume they mean linting here. It's about 70% faster. Now, why does this matter? because developers can build their applications with confidence knowing that the type safety we offer is not only fast but has less overhead. This is a really empty statement, man. And I don't think anyone really

### Segment 4 (15:00 - 16:00) [15:00]

experiences any benefit here, but it looks cool and it's a good change, man. Like, they can actually be proud of this. This is I don't want to talk this down. Good change, but probably not so many people will care as, for example, ripping out the Rust engine. I also want to skip over the whole Prisma Postgress part. It's a ventureback company. They need to make money somehow and OM is hard. So having a native database integration makes a lot of sense for them, but it's not really part of the update. And I want to get to the summary. We've spent countless hours working through our backlog of issues and feature requests to address some of the top requested ones like mapped enums updating the minimum version of node and typescript required for projects as well as a brand new version of prisma studio which they absolutely cooked with. This looks really nice. I think a lot nicer even than the drizzle studio which I think they emulated from Prisma. So it's not like anyone is stealing from the other here. It is actually a kind of convergence and being inspired by each other which I think is totally fair. You know, everyone has their own benchmarks. I use Drizzle in my personal projects. Prisma is a really good choice. Even better so now. And that's it for the Prisma 7 update. It's the foundation of what comes next for Prisma ORM and Prisma Postgres. Cool man. I would encourage you to try Prisma 7. I will in the following days as well to see how it works in my own projects. And who knows, man, I might just switch over from Drizzle or not, depending on how it feels. I really hope you enjoyed this video. I'm going to see you in the next one. Until then, have a good one and bye-bye.
