Skip to content

Commit 19f10b4

Browse files
committed
feat: add simplified runtime options for prisma-client DC-4868
1 parent e5ae067 commit 19f10b4

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed

content/200-orm/100-prisma-schema/10-overview/03-generators.mdx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,11 +212,17 @@ Below are the options for the `prisma-client` generator:
212212
| **Option** | **Default** | **Description** |
213213
| ------------------------ | ------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
214214
| `output` (**required**) | | Directory where Prisma Client is generated, e.g. `../src/generated/prisma`. |
215-
| `runtime` | `nodejs` | Target runtime environment. <br />Supported values: <br />`nodejs` (alias `node`), `deno`, `bun`, `deno-deploy`, `workerd` (alias `cloudflare`), `edge-light` (alias `vercel`), `react-native`. |
215+
| `runtime` | `nodejs` | Target runtime environment. <br />Supported values: <br />`nodejs`, `deno`, `bun`, `workerd` (alias `cloudflare`), `vercel-edge` (alias `edge-light`), `react-native`. |
216216
| `moduleFormat` | Inferred from environment | Module format (`esm` or `cjs`). Determines whether `import.meta.url` or `__dirname` is used. |
217217
| `generatedFileExtension` | `ts` | File extension for generated TypeScript files (`ts`, `mts`, `cts`). |
218218
| `importFileExtension` | Inferred from environment | File extension used in **import statements**. Can be `ts`, `mts`, `cts`, `js`, `mjs`, `cjs`, or empty (for bare imports). |
219219

220+
:::note
221+
222+
`nodejs`, `deno`, and `bun` all map to the same internal codepath but are preserved as separate user-facing values for clarity.
223+
224+
:::
225+
220226
### Output splitting and importing types
221227

222228
The `prisma-client-js` generator used to generate all typings into a single `index.d.ts` file, which could lead to [slowing down editors](https://github.com/prisma/prisma/issues/4807) (e.g. breaking auto-complete) with large schemas.

content/200-orm/500-reference/100-prisma-schema-reference.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ A `generator` block accepts the following fields:
187187
| `provider` | **Yes** | `prisma-client` | Describes which [generator](/orm/prisma-schema/overview/generators) to use. This can point to a file that implements a generator or specify a built-in generator directly. |
188188
| `output` | **Yes** | String (file path) | Determines the location for the generated client, [learn more](/orm/prisma-client/setup-and-configuration/generating-prisma-client#using-a-custom-output-path). |
189189
| `previewFeatures` | No | List of Enums | Use intellisense to see list of currently available Preview features (`Ctrl+Space` in Visual Studio Code) **Default**: none |
190-
| `runtime` | No | Enum (`nodejs` (alias `node`), `deno`, `bun`, `deno-deploy`, `workerd` (alias `cloudflare`), `edge-light` (alias `vercel`), `react-native`) | Target runtime environment. **Default**: `nodejs` |
190+
| `runtime` | No | Enum (`nodejs`, `deno`, `bun`, `workerd` (alias `cloudflare`), `vercel-edge` (alias `edge-light`), `react-native`) | Target runtime environment. **Default**: `nodejs` |
191191
| `moduleFormat` | No | Enum (`esm` or `cjs`) | Determines whether the generated code supports ESM (uses `import`) or CommonJS (uses `require(...)`) modules. We always recommend `esm` unless you have a good reason to use `cjs`. **Default**: Inferred from environment. |
192192
| `generatedFileExtension` | No | Enum (`ts` or `mts` or `cts`) | File extension for generated TypeScript files. **Default**: `ts` |
193193
| `importFileExtension` | No | Enum (`ts`,`mts`,`cts`,`js`,`mjs`,`cjs`, empty (for bare imports)) | File extension used in import statements **Default**: Inferred from environment. |

content/250-postgres/100-introduction/220-npx-create-db.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,7 @@ Here are the CLI flags for the `npx create-db` command:
146146
|---------------|-----------|----------------------------------------------------------------------------------------------|
147147
| `--region` | `-r` | Specify a region. <br /> **Available regions:** `ap-southeast-1`, `ap-northeast-1`, `eu-central-1`, `eu-west-3`, `us-east-1`, `us-west-1` |
148148
| `--interactive` | `-i` | Run in interactive mode (select region from a list). |
149+
| `--json` | `-j` | Output machine-readable JSON and exit. |
149150
| `--help` | `-h` | Show this help message. |
150151

151152

0 commit comments

Comments
 (0)