prisma-zod-generator 0.7.1 → 0.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -7
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -108,17 +108,19 @@ app.post('/blog', async (req, res, next) => {
|
|
|
108
108
|
|
|
109
109
|
## Additional Options
|
|
110
110
|
|
|
111
|
-
| Option
|
|
112
|
-
|
|
|
113
|
-
| `output`
|
|
114
|
-
| `isGenerateSelect`
|
|
111
|
+
| Option | Description | Type | Default |
|
|
112
|
+
| ------------------- | -------------------------------------------------------------------------- | --------- | ------------- |
|
|
113
|
+
| `output` | Output directory for the generated zod schemas | `string` | `./generated` |
|
|
114
|
+
| `isGenerateSelect` | Enables the generation of Select related schemas and the select property | `boolean` | `false` |
|
|
115
|
+
| `isGenerateInclude` | Enables the generation of Include related schemas and the include property | `boolean` | `false` |
|
|
115
116
|
|
|
116
117
|
Use additional options in the `schema.prisma`
|
|
117
118
|
|
|
118
119
|
```prisma
|
|
119
120
|
generator zod {
|
|
120
|
-
provider
|
|
121
|
-
output
|
|
122
|
-
isGenerateSelect
|
|
121
|
+
provider = "prisma-zod-generator"
|
|
122
|
+
output = "./generated-zod-schemas"
|
|
123
|
+
isGenerateSelect = true
|
|
124
|
+
isGenerateInclude = true
|
|
123
125
|
}
|
|
124
126
|
```
|
package/package.json
CHANGED