Hey <!everyone> :v: We just released Prisma <2.3.0...
# prisma-whats-new
t
Hey <!everyone> โœŒ๏ธ We just released Prisma 2.3.0 prisma rainbow Here is whatโ€™s new in this version ๐Ÿ“ Rename Helper Tool in VSCode Extension Thanks to @Carmen, you can now easily rename models and enums with the VSCode extension in your schema. ๐Ÿ•ต๏ธโ€โ™€๏ธ Introspection uses order of columns in table to order fields in model
prisma introspect
until recently ordered all fields in models alphabetically. Starting with 2.3.0 it now picks up the order from the columns in your database table and uses that same order for the fields in your models in your Prisma Schema file. prisma cool Experimental features have been renamed to preview features With
2.1.0
we introduced feature flags for Prisma Client, called โ€œExperimental Featuresโ€. The property in the schema has been renamed from
experimentalFeatures
to
previewFeatures
to better communicate what they actually are. ๐Ÿฆ• Distinct API (preview) We introduce distinct querying capabilities to Prisma Client. It allows you to query for distinct (unique) rows of a model.
Copy code
const result = await prisma.user.findMany({
  where: {},
  distinct: ['name']
})
๐Ÿ„ Middlewares API (preview) Inspired by Koa - Prisma Client now allows you to provide powerful async middlewares.
Copy code
prisma.use(async (params, next) => {
  console.log('params', params)
  const before = Date.now()
  const result = await next(params)
  const after = Date.now()
  console.log(`Query ${params.model}.${params.action} took ${after - before}ms`)
  return result
})
You can learn more about all features and fixes in theย release notes, weโ€™re looking forward to your feedback for the new version!
๐Ÿฆ• 4
๐Ÿ‡ต๐Ÿ‡ฐ 7
๐Ÿ‡จ๐Ÿ‡ต 3
๐Ÿ‡จ๐Ÿ‡ฆ 5
๐Ÿ‡ฎ๐Ÿ‡น 4
๐Ÿ‡ป๐Ÿ‡ณ 1
๐Ÿ‡น๐Ÿ‡ฟ 1
๐Ÿ‡ง๐Ÿ‡ท 3
๐Ÿ‘€ 62
๐Ÿ‡ฐ๐Ÿ‡ท 25
windows 19
pakistan parrot 13
๐Ÿ‡ฎ๐Ÿ‡ณ 12
๐Ÿคฉ 12
๐Ÿฐ 9
๐Ÿ‡ฌ๐Ÿ‡ญ 2
๐Ÿ‡ฌ๐Ÿ‡ท 3
๐Ÿ‡ซ๐Ÿ‡ท 6
๐Ÿด๓ ง๓ ข๓ ณ๓ ฃ๓ ด๓ ฟ 1
โค๏ธ 89
๐Ÿงžโ€โ™‚๏ธ 19
๐Ÿ‘ฉโ€๐Ÿš€ 13
๐Ÿ’ฏ 17
pokemon bulbasaur 10
๐Ÿ”ฅ 17
๐Ÿ˜Ž 14
๐Ÿ‡ป๐Ÿ‡ช 4
๐Ÿ‡จ๐Ÿ‡ณ 4
๐Ÿ‡บ๐Ÿ‡ธ 1
fast parrot 72
prisma rainbow 64
๐Ÿพ 24
๐Ÿš€ 34
๐Ÿ‘ 15
๐Ÿ‡ณ๐Ÿ‡ต 8
india parrot 8
๐Ÿ‡ต๐Ÿ‡ญ 4
๐Ÿ‡ณ๐Ÿ‡ฌ 12
๐Ÿ‡ณ๐Ÿ‡ฑ 3
๐Ÿ‡ฏ๐Ÿ‡ฒ 1
๐Ÿ‡ฌ๐Ÿ‡ช 1