@prisma/sdk
4.0.0 · 28 Jun 2022Apache-2.040.1k / weekRepositoryHomepagenpmAtom feed
2.30.3 is the newest release of 2.x.
In short
18 new2 changed
Release note
Today, we are excited to share the 2.24.0 stable release 🎉
🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟
Major improvements & new features
MongoDB gets Json and Enum Support
We just added Json and enum support to the MongoDB provider for Prisma Client. Here's an example with both:
datasource db {
provider = "mongodb"
url = env("DATABASE_URL")
}
generator client {
provider = "prisma-client-js"
previewFeatures = ["mongodb"]
}
model Log {
id String @id @default(dbgenerated()) @map("_id") @db.ObjectId
message String
level Level @default(Info)
meta Json
}
enum Level {
Info
Warn
Error
}You can then use the generated client like this:
await prisma.log.create({
data: {
level: "info",
message: "User signed in",
meta: { user_id: 1 },
},
})As a reminder, the mongodb provider is still in Early Access. If you'd like to use MongoDB with Prisma, please fill out this 2-minute Typeform and we'll get you an invite to our Getting Started Guide and private Slack channel right away!
New features for the Prisma Data Platform
The Prisma Data Platform (PDP) helps developers collaborate better in projects that are using the open-source tools. One of its main features today is an online data browser.
View schema
You can now view your project's schema in order to better understand your application or collaborate with your colleagues. The only roles that can view it are: Admin and Developer
Expand for a screenshot of the new schema view
Delete & edit your project
You can now delete your project from your settings.
Expand for a screenshot of the new settings
You can also edit your Project's URL, so you can now correct any mistakes you might have made while creating your project.
Static IPs are now supported
If your database is behind a proxy and you need a static IP to allowlist in order to give access to it, you can now get in touch with us by creating an issue or sending an email at martzoukos@prisma.io and we'll enable it for you.
Please note that while this feature is freely available now, it will be offered as part of a paid plan in the future (towards the end of '21 or beginning of '22).
Fixes and improvements
Prisma Client
Prisma CLI installation hangs indefinitely inside of docker (Kernel 5.10)
PANIC in query-engine\core\src\interpreter\query_interpreters\nested_read.rs:79:561
Prisma Migrate
Prisma Studio
Prisma Engines
Parse type names in datamodel parser at the pest level instead of regular expressions
[N-API] Export Functional Engine Commands along side QueryEngine Constructor
Join us for another "What's new in Prisma" livestream
Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" livestream.
The stream takes place on Youtube on Thursday, June 3rd at 5pm Berlin | 8am San Francisco.
Prisma Day is coming
Save the date for Prisma Day 2021 and join us for two days of talks and workshops by the most exciting members of the Prisma community.
June 29th: Workshops
June 30th: Talks
We look forward to seeing you there!
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.