npm prisma 2.24.0

latest releases: 5.23.0-integration-engines-5-23-0-6-integration-enum-mapped-values-cc1d5ee45ff9a116165edca8ab47690e5133baf0.2, 5.23.0-integration-engines-5-23-0-6-integration-enum-mapped-values-cc1d5ee45ff9a116165edca8ab47690e5133baf0.1, 5.23.0-dev.7...
3 years ago

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 View your Schema

Delete & edit your project

You can now delete your project from your settings.

Expand for a screenshot of the new settings Delete your Project

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 Migrate

Prisma Studio

Prisma Engines

Credits

Huge thanks to @Sytten for helping!

📺 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!

Don't miss a new prisma release

NewReleases is sending notifications on new releases.