refract
refract copied to clipboard
Generate Prisma from TypeScript
According to the official Prisma [documentation](https://www.prisma.io/docs/concepts/components/prisma-schema#comments), several types of comments are supported: - the standard `//`, which are not saved in AST - and those that are saved in AST...
As described here: https://www.prisma.io/docs/concepts/components/prisma-schema/data-model#defining-composite-types It is possible to define composite types with mongodb, like this: ``` model Product { id String @id @default(auto()) @map("_id") @db.ObjectId name String photos Photo[] }...
I think it'd be nice if the codegen function was exposed, because maybe people don't want to write a file. I imagine this would be exposing the default exported function...
Adds support for the use of [Composite Types](https://www.prisma.io/docs/orm/prisma-schema/data-model/models#defining-composite-types) for MongoDB. Between the commit changes is a modified [README ](https://github.com/giuliano-marinelli/refract/blob/main/README.md#composite-types)that shows how to use the new behaviour implemented. It also pass...