@prisma/client-generator-ts 6.19.0-integration-engines-6-19-0-2-push-qtpkxwkvolmz-33c9120129ea6df44eaf652b4de9bedd817e3190.1 → 6.19.0-integration-next.6
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/dist/TSClient/NullTypes.d.ts +1 -1
- package/dist/TSClient/PrismaClient.d.ts +0 -1
- package/dist/TSClient/TSClient.d.ts +1 -1
- package/dist/generateClient.d.ts +1 -3
- package/dist/index.d.mts +1 -3
- package/dist/index.d.ts +1 -3
- package/dist/index.js +34 -58
- package/dist/index.mjs +34 -58
- package/dist/runtime-targets.d.ts +3 -3
- package/package.json +10 -10
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const nullTypes = "\nexport const NullTypes = {\n DbNull: runtime.
|
|
1
|
+
export declare const nullTypes = "\nexport const NullTypes = {\n DbNull: runtime.NullTypes.DbNull as (new (secret: never) => typeof runtime.DbNull),\n JsonNull: runtime.NullTypes.JsonNull as (new (secret: never) => typeof runtime.JsonNull),\n AnyNull: runtime.NullTypes.AnyNull as (new (secret: never) => typeof runtime.AnyNull),\n}\n/**\n * Helper for filtering JSON entries that have `null` on the database (empty on the db)\n *\n * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field\n */\nexport const DbNull = runtime.DbNull\n\n/**\n * Helper for filtering JSON entries that have JSON `null` values (not empty on the db)\n *\n * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field\n */\nexport const JsonNull = runtime.JsonNull\n\n/**\n * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull`\n *\n * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field\n */\nexport const AnyNull = runtime.AnyNull\n";
|
|
@@ -3,7 +3,7 @@ import { DMMFHelper } from '../dmmf';
|
|
|
3
3
|
import type { FileMap } from '../generateClient';
|
|
4
4
|
import { GenerateClientOptions } from '../generateClient';
|
|
5
5
|
import { GenericArgsInfo } from '../GenericsArgsInfo';
|
|
6
|
-
export type RuntimeName = 'binary' | 'library' | 'wasm-
|
|
6
|
+
export type RuntimeName = 'binary' | 'library' | 'wasm-compiler-edge' | 'client' | (string & {});
|
|
7
7
|
export type TSClientOptions = O.Required<GenerateClientOptions, 'runtimeBase'> & {
|
|
8
8
|
/** The name of the runtime bundle to use */
|
|
9
9
|
runtimeName: RuntimeName;
|
package/dist/generateClient.d.ts
CHANGED
|
@@ -26,8 +26,6 @@ export interface GenerateClientOptions {
|
|
|
26
26
|
envPaths?: EnvPaths;
|
|
27
27
|
/** When --postinstall is passed via CLI */
|
|
28
28
|
postinstall?: boolean;
|
|
29
|
-
/** False when --no-engine is passed via CLI */
|
|
30
|
-
copyEngine?: boolean;
|
|
31
29
|
typedSql?: SqlQueryOutput[];
|
|
32
30
|
target: RuntimeTargetInternal;
|
|
33
31
|
generatedFileExtension: GeneratedFileExtension;
|
|
@@ -43,5 +41,5 @@ export interface BuildClientResult {
|
|
|
43
41
|
fileMap: FileMap;
|
|
44
42
|
prismaClientDmmf: DMMF.Document;
|
|
45
43
|
}
|
|
46
|
-
export declare function buildClient({ schemaPath, runtimeBase, datamodel, binaryPaths, outputDir, generator, dmmf, datasources, engineVersion, clientVersion, activeProvider, postinstall,
|
|
44
|
+
export declare function buildClient({ schemaPath, runtimeBase, datamodel, binaryPaths, outputDir, generator, dmmf, datasources, engineVersion, clientVersion, activeProvider, postinstall, envPaths, typedSql, target, generatedFileExtension, importFileExtension, moduleFormat, tsNoCheckPreamble, }: O.Required<GenerateClientOptions, 'runtimeBase'>): BuildClientResult;
|
|
47
45
|
export declare function generateClient(options: GenerateClientOptions): Promise<void>;
|
package/dist/index.d.mts
CHANGED
|
@@ -40,8 +40,6 @@ export declare interface GenerateClientOptions {
|
|
|
40
40
|
envPaths?: EnvPaths;
|
|
41
41
|
/** When --postinstall is passed via CLI */
|
|
42
42
|
postinstall?: boolean;
|
|
43
|
-
/** False when --no-engine is passed via CLI */
|
|
44
|
-
copyEngine?: boolean;
|
|
45
43
|
typedSql?: SqlQueryOutput[];
|
|
46
44
|
target: RuntimeTargetInternal;
|
|
47
45
|
generatedFileExtension: GeneratedFileExtension;
|
|
@@ -72,6 +70,6 @@ export declare class PrismaClientTsGenerator implements Generator_2 {
|
|
|
72
70
|
*/
|
|
73
71
|
declare type RuntimeTargetInternal = (typeof supportedInternalRuntimes)[number];
|
|
74
72
|
|
|
75
|
-
declare const supportedInternalRuntimes: readonly ["nodejs", "workerd", "vercel-edge", "deno"
|
|
73
|
+
declare const supportedInternalRuntimes: readonly ["nodejs", "workerd", "vercel-edge", "deno"];
|
|
76
74
|
|
|
77
75
|
export { }
|
package/dist/index.d.ts
CHANGED
|
@@ -40,8 +40,6 @@ export declare interface GenerateClientOptions {
|
|
|
40
40
|
envPaths?: EnvPaths;
|
|
41
41
|
/** When --postinstall is passed via CLI */
|
|
42
42
|
postinstall?: boolean;
|
|
43
|
-
/** False when --no-engine is passed via CLI */
|
|
44
|
-
copyEngine?: boolean;
|
|
45
43
|
typedSql?: SqlQueryOutput[];
|
|
46
44
|
target: RuntimeTargetInternal;
|
|
47
45
|
generatedFileExtension: GeneratedFileExtension;
|
|
@@ -72,6 +70,6 @@ export declare class PrismaClientTsGenerator implements Generator_2 {
|
|
|
72
70
|
*/
|
|
73
71
|
declare type RuntimeTargetInternal = (typeof supportedInternalRuntimes)[number];
|
|
74
72
|
|
|
75
|
-
declare const supportedInternalRuntimes: readonly ["nodejs", "workerd", "vercel-edge", "deno"
|
|
73
|
+
declare const supportedInternalRuntimes: readonly ["nodejs", "workerd", "vercel-edge", "deno"];
|
|
76
74
|
|
|
77
75
|
export { }
|
package/dist/index.js
CHANGED
|
@@ -2385,7 +2385,7 @@ var Enum = class {
|
|
|
2385
2385
|
toTS() {
|
|
2386
2386
|
const { type } = this;
|
|
2387
2387
|
const enumVariants = `{
|
|
2388
|
-
${(0, import_indent_string.default)(type.
|
|
2388
|
+
${(0, import_indent_string.default)(type.data.map((v) => `${v.key}: ${this.getValue(v.value)}`).join(",\n"), TAB_SIZE)}
|
|
2389
2389
|
} as const`;
|
|
2390
2390
|
const enumBody = this.isStrictEnum() ? `runtime.makeStrictEnum(${enumVariants})` : enumVariants;
|
|
2391
2391
|
return `export const ${type.name} = ${enumBody}
|
|
@@ -2939,7 +2939,6 @@ ${modelExports(context).join("\n")}
|
|
|
2939
2939
|
}
|
|
2940
2940
|
|
|
2941
2941
|
// src/TSClient/file-generators/ClassFile.ts
|
|
2942
|
-
var import_node_crypto = __toESM(require("node:crypto"));
|
|
2943
2942
|
var import_node_path2 = __toESM(require("node:path"));
|
|
2944
2943
|
var import_internals4 = require("@prisma/internals");
|
|
2945
2944
|
var ts6 = __toESM(require("@prisma/ts-builders"));
|
|
@@ -3456,7 +3455,7 @@ function escapeJson(str) {
|
|
|
3456
3455
|
function buildRuntimeDataModel(datamodel, runtimeName) {
|
|
3457
3456
|
const runtimeDataModel = (0, import_client_common10.dmmfToRuntimeDataModel)(datamodel);
|
|
3458
3457
|
let prunedDataModel;
|
|
3459
|
-
if (runtimeName === "wasm-
|
|
3458
|
+
if (runtimeName === "wasm-compiler-edge" || runtimeName === "client") {
|
|
3460
3459
|
prunedDataModel = (0, import_client_common10.pruneRuntimeDataModel)(runtimeDataModel);
|
|
3461
3460
|
} else {
|
|
3462
3461
|
prunedDataModel = runtimeDataModel;
|
|
@@ -3488,7 +3487,7 @@ var import_debug = require("@prisma/debug");
|
|
|
3488
3487
|
var import_ts_pattern = require("ts-pattern");
|
|
3489
3488
|
var debug = (0, import_debug.Debug)("prisma:client-generator-ts:wasm");
|
|
3490
3489
|
function usesEdgeWasmRuntime(component, runtimeName) {
|
|
3491
|
-
return runtimeName === "wasm-
|
|
3490
|
+
return runtimeName === "wasm-compiler-edge" && component === "compiler";
|
|
3492
3491
|
}
|
|
3493
3492
|
function buildGetWasmModule({
|
|
3494
3493
|
component,
|
|
@@ -3849,7 +3848,6 @@ ${[
|
|
|
3849
3848
|
interactiveTransactionDefinition(this.context),
|
|
3850
3849
|
runCommandRawDefinition(this.context),
|
|
3851
3850
|
metricDefinition(this.context),
|
|
3852
|
-
this.applyPendingMigrationsDefinition(),
|
|
3853
3851
|
extendsPropertyDefinition()
|
|
3854
3852
|
].filter((d) => d !== null).join("\n").trim()}
|
|
3855
3853
|
|
|
@@ -3874,15 +3872,6 @@ get ${methodName}(): Prisma.${m.model}Delegate<${generics.join(", ")}>;`;
|
|
|
3874
3872
|
)}
|
|
3875
3873
|
}`;
|
|
3876
3874
|
}
|
|
3877
|
-
applyPendingMigrationsDefinition() {
|
|
3878
|
-
if (this.runtimeName !== "react-native") {
|
|
3879
|
-
return null;
|
|
3880
|
-
}
|
|
3881
|
-
const method3 = ts5.method("$applyPendingMigrations").setReturnType(promise(ts5.voidType)).setDocComment(
|
|
3882
|
-
ts5.docComment`Tries to apply pending migrations one by one. If a migration fails to apply, the function will stop and throw an error. You are responsible for informing the user and possibly blocking the app as we cannot guarantee the state of the database.`
|
|
3883
|
-
);
|
|
3884
|
-
return ts5.stringify(method3, { indentLevel: 1, newLine: "leading" });
|
|
3885
|
-
}
|
|
3886
3875
|
};
|
|
3887
3876
|
|
|
3888
3877
|
// src/TSClient/file-generators/ClassFile.ts
|
|
@@ -3923,14 +3912,12 @@ function clientConfig(context, options) {
|
|
|
3923
3912
|
runtimeBase,
|
|
3924
3913
|
runtimeName,
|
|
3925
3914
|
datasources,
|
|
3926
|
-
copyEngine = true,
|
|
3927
3915
|
target,
|
|
3928
3916
|
activeProvider,
|
|
3929
3917
|
moduleFormat
|
|
3930
3918
|
} = options;
|
|
3931
3919
|
const clientEngineType = (0, import_internals4.getClientEngineType)(generator);
|
|
3932
3920
|
generator.config.engineType = clientEngineType;
|
|
3933
|
-
const inlineSchemaHash = import_node_crypto.default.createHash("sha256").update(Buffer.from(inlineSchema, "utf8").toString("base64")).digest("hex");
|
|
3934
3921
|
const datasourceFilePath = datasources[0].sourceFilePath;
|
|
3935
3922
|
const config = {
|
|
3936
3923
|
generator,
|
|
@@ -3943,8 +3930,6 @@ function clientConfig(context, options) {
|
|
|
3943
3930
|
ciName: import_ci_info.default.name ?? void 0,
|
|
3944
3931
|
inlineDatasources: buildInlineDatasources(datasources),
|
|
3945
3932
|
inlineSchema,
|
|
3946
|
-
inlineSchemaHash,
|
|
3947
|
-
copyEngine,
|
|
3948
3933
|
runtimeDataModel: { models: {}, enums: {}, types: {} },
|
|
3949
3934
|
dirname: ""
|
|
3950
3935
|
};
|
|
@@ -4051,7 +4036,7 @@ ${imports.join("\n")}
|
|
|
4051
4036
|
${exports2.join("\n")}
|
|
4052
4037
|
export { Prisma }
|
|
4053
4038
|
|
|
4054
|
-
${buildNFTAnnotations(options.edge
|
|
4039
|
+
${buildNFTAnnotations(options.edge, clientEngineType, binaryTargets, relativeOutdir)}
|
|
4055
4040
|
|
|
4056
4041
|
${modelExports(context).join("\n")}
|
|
4057
4042
|
`;
|
|
@@ -5153,33 +5138,36 @@ function createModelsFile(context, modelsNames) {
|
|
|
5153
5138
|
}
|
|
5154
5139
|
|
|
5155
5140
|
// src/TSClient/file-generators/PrismaNamespaceBrowserFile.ts
|
|
5141
|
+
var import_dmmf2 = require("@prisma/dmmf");
|
|
5156
5142
|
var ts16 = __toESM(require("@prisma/ts-builders"));
|
|
5157
5143
|
|
|
5158
5144
|
// src/TSClient/NullTypes.ts
|
|
5159
5145
|
var nullTypes = `
|
|
5160
5146
|
export const NullTypes = {
|
|
5161
|
-
DbNull: runtime.
|
|
5162
|
-
JsonNull: runtime.
|
|
5163
|
-
AnyNull: runtime.
|
|
5147
|
+
DbNull: runtime.NullTypes.DbNull as (new (secret: never) => typeof runtime.DbNull),
|
|
5148
|
+
JsonNull: runtime.NullTypes.JsonNull as (new (secret: never) => typeof runtime.JsonNull),
|
|
5149
|
+
AnyNull: runtime.NullTypes.AnyNull as (new (secret: never) => typeof runtime.AnyNull),
|
|
5164
5150
|
}
|
|
5165
5151
|
/**
|
|
5166
5152
|
* Helper for filtering JSON entries that have \`null\` on the database (empty on the db)
|
|
5167
5153
|
*
|
|
5168
5154
|
* @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
|
|
5169
5155
|
*/
|
|
5170
|
-
export const DbNull = runtime.
|
|
5156
|
+
export const DbNull = runtime.DbNull
|
|
5157
|
+
|
|
5171
5158
|
/**
|
|
5172
5159
|
* Helper for filtering JSON entries that have JSON \`null\` values (not empty on the db)
|
|
5173
5160
|
*
|
|
5174
5161
|
* @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
|
|
5175
5162
|
*/
|
|
5176
|
-
export const JsonNull = runtime.
|
|
5163
|
+
export const JsonNull = runtime.JsonNull
|
|
5164
|
+
|
|
5177
5165
|
/**
|
|
5178
5166
|
* Helper for filtering JSON entries that are \`Prisma.DbNull\` or \`Prisma.JsonNull\`
|
|
5179
5167
|
*
|
|
5180
5168
|
* @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
|
|
5181
5169
|
*/
|
|
5182
|
-
export const AnyNull = runtime.
|
|
5170
|
+
export const AnyNull = runtime.AnyNull
|
|
5183
5171
|
`;
|
|
5184
5172
|
|
|
5185
5173
|
// src/TSClient/file-generators/PrismaNamespaceBrowserFile.ts
|
|
@@ -5196,7 +5184,9 @@ var jsDocHeader7 = `/*
|
|
|
5196
5184
|
*/
|
|
5197
5185
|
`;
|
|
5198
5186
|
function createPrismaNamespaceBrowserFile(context) {
|
|
5199
|
-
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5187
|
+
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5188
|
+
(datamodelEnum) => new Enum((0, import_dmmf2.datamodelSchemaEnumToSchemaEnum)(datamodelEnum), false).toTS()
|
|
5189
|
+
);
|
|
5200
5190
|
return `${jsDocHeader7}
|
|
5201
5191
|
${ts16.stringify(ts16.moduleImport(`${context.runtimeBase}/index-browser`).asNamespace("runtime"))}
|
|
5202
5192
|
|
|
@@ -5210,7 +5200,10 @@ ${nullTypes}
|
|
|
5210
5200
|
${new Enum(
|
|
5211
5201
|
{
|
|
5212
5202
|
name: "ModelName",
|
|
5213
|
-
|
|
5203
|
+
data: context.dmmf.mappings.modelOperations.map((m) => ({
|
|
5204
|
+
key: m.model,
|
|
5205
|
+
value: m.model
|
|
5206
|
+
}))
|
|
5214
5207
|
},
|
|
5215
5208
|
true
|
|
5216
5209
|
).toTS()}
|
|
@@ -5223,6 +5216,7 @@ ${prismaEnums?.join("\n\n")}
|
|
|
5223
5216
|
}
|
|
5224
5217
|
|
|
5225
5218
|
// src/TSClient/file-generators/PrismaNamespaceFile.ts
|
|
5219
|
+
var import_dmmf3 = require("@prisma/dmmf");
|
|
5226
5220
|
var ts19 = __toESM(require("@prisma/ts-builders"));
|
|
5227
5221
|
|
|
5228
5222
|
// src/TSClient/common.ts
|
|
@@ -5762,7 +5756,9 @@ function createPrismaNamespaceFile(context, options) {
|
|
|
5762
5756
|
ts19.moduleImport(context.importFileName(`../models`)).asNamespace("Prisma").typeOnly(),
|
|
5763
5757
|
ts19.moduleImport(context.importFileName(`./class`)).named(ts19.namedImport("PrismaClient").typeOnly())
|
|
5764
5758
|
].map((i) => ts19.stringify(i));
|
|
5765
|
-
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5759
|
+
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5760
|
+
(type) => new Enum((0, import_dmmf3.datamodelSchemaEnumToSchemaEnum)(type), true).toTS()
|
|
5761
|
+
);
|
|
5766
5762
|
const fieldRefs = context.dmmf.schema.fieldRefTypes.prisma?.map((type) => new FieldRefInput(type).toTS()) ?? [];
|
|
5767
5763
|
return `${jsDocHeader8}
|
|
5768
5764
|
${imports.join("\n")}
|
|
@@ -5773,7 +5769,10 @@ ${commonCodeTS(options)}
|
|
|
5773
5769
|
${new Enum(
|
|
5774
5770
|
{
|
|
5775
5771
|
name: "ModelName",
|
|
5776
|
-
|
|
5772
|
+
data: context.dmmf.mappings.modelOperations.map((m) => ({
|
|
5773
|
+
key: m.model,
|
|
5774
|
+
value: m.model
|
|
5775
|
+
}))
|
|
5777
5776
|
},
|
|
5778
5777
|
true
|
|
5779
5778
|
).toTS()}
|
|
@@ -5883,8 +5882,6 @@ function clientExtensionsDefinitions() {
|
|
|
5883
5882
|
function buildClientOptions(context, options) {
|
|
5884
5883
|
const clientOptions = ts19.interfaceDeclaration("PrismaClientOptions").add(
|
|
5885
5884
|
ts19.property("datasources", ts19.namedType("Datasources")).optional().setDocComment(ts19.docComment("Overwrites the datasource url from your schema.prisma file"))
|
|
5886
|
-
).add(
|
|
5887
|
-
ts19.property("datasourceUrl", ts19.stringType).optional().setDocComment(ts19.docComment("Overwrites the datasource url from your schema.prisma file"))
|
|
5888
5885
|
).add(
|
|
5889
5886
|
ts19.property("errorFormat", ts19.namedType("ErrorFormat")).optional().setDocComment(ts19.docComment('@default "colorless"'))
|
|
5890
5887
|
).add(
|
|
@@ -5924,7 +5921,7 @@ function buildClientOptions(context, options) {
|
|
|
5924
5921
|
timeout ?= 5000
|
|
5925
5922
|
`)
|
|
5926
5923
|
);
|
|
5927
|
-
if (["library", "client", "wasm-compiler-edge"
|
|
5924
|
+
if (["library", "client", "wasm-compiler-edge"].includes(options.runtimeName)) {
|
|
5928
5925
|
clientOptions.add(
|
|
5929
5926
|
ts19.property("adapter", ts19.unionType([ts19.namedType("runtime.SqlDriverAdapterFactory"), ts19.namedType("null")])).optional().setDocComment(
|
|
5930
5927
|
ts19.docComment("Instance of a Driver Adapter, e.g., like one provided by `@prisma/adapter-planetscale`")
|
|
@@ -6292,7 +6289,6 @@ function buildClient({
|
|
|
6292
6289
|
clientVersion,
|
|
6293
6290
|
activeProvider,
|
|
6294
6291
|
postinstall,
|
|
6295
|
-
copyEngine,
|
|
6296
6292
|
envPaths,
|
|
6297
6293
|
typedSql,
|
|
6298
6294
|
target,
|
|
@@ -6318,9 +6314,8 @@ function buildClient({
|
|
|
6318
6314
|
engineVersion,
|
|
6319
6315
|
activeProvider,
|
|
6320
6316
|
postinstall,
|
|
6321
|
-
copyEngine,
|
|
6322
6317
|
datamodel,
|
|
6323
|
-
edge: ["
|
|
6318
|
+
edge: ["wasm-compiler-edge"].includes(runtimeName),
|
|
6324
6319
|
runtimeName,
|
|
6325
6320
|
target,
|
|
6326
6321
|
generatedFileExtension,
|
|
@@ -6328,9 +6323,6 @@ function buildClient({
|
|
|
6328
6323
|
moduleFormat,
|
|
6329
6324
|
tsNoCheckPreamble: tsNoCheckPreamble2
|
|
6330
6325
|
};
|
|
6331
|
-
if (runtimeName === "react-native" && !generator.previewFeatures.includes("reactNative")) {
|
|
6332
|
-
throw new Error(`Using the "react-native" runtime requires the "reactNative" preview feature to be enabled.`);
|
|
6333
|
-
}
|
|
6334
6326
|
const client = new TSClient(clientOptions);
|
|
6335
6327
|
let fileMap = client.generateClientFiles();
|
|
6336
6328
|
if (typedSql && typedSql.length > 0) {
|
|
@@ -6386,7 +6378,6 @@ async function generateClient(options) {
|
|
|
6386
6378
|
activeProvider,
|
|
6387
6379
|
postinstall,
|
|
6388
6380
|
envPaths,
|
|
6389
|
-
copyEngine = true,
|
|
6390
6381
|
typedSql,
|
|
6391
6382
|
target,
|
|
6392
6383
|
generatedFileExtension,
|
|
@@ -6409,7 +6400,6 @@ async function generateClient(options) {
|
|
|
6409
6400
|
engineVersion,
|
|
6410
6401
|
activeProvider,
|
|
6411
6402
|
postinstall,
|
|
6412
|
-
copyEngine,
|
|
6413
6403
|
envPaths,
|
|
6414
6404
|
typedSql,
|
|
6415
6405
|
target,
|
|
@@ -6435,7 +6425,7 @@ To learn more about how to rename models, check out https://pris.ly/d/naming-mod
|
|
|
6435
6425
|
await (0, import_fs_extra.ensureDir)(outputDir);
|
|
6436
6426
|
await writeFileMap(outputDir, fileMap);
|
|
6437
6427
|
const enginePath = clientEngineType === import_internals10.ClientEngineType.Library ? binaryPaths.libqueryEngine : binaryPaths.queryEngine;
|
|
6438
|
-
if (
|
|
6428
|
+
if (enginePath) {
|
|
6439
6429
|
if (process.env.NETLIFY) {
|
|
6440
6430
|
await (0, import_fs_extra.ensureDir)("/tmp/prisma-engines");
|
|
6441
6431
|
}
|
|
@@ -6560,9 +6550,7 @@ function getRuntimeNameForTarget(target, engineType) {
|
|
|
6560
6550
|
return getNodeRuntimeName(engineType);
|
|
6561
6551
|
case "workerd":
|
|
6562
6552
|
case "vercel-edge":
|
|
6563
|
-
return
|
|
6564
|
-
case "react-native":
|
|
6565
|
-
return "react-native";
|
|
6553
|
+
return "wasm-compiler-edge";
|
|
6566
6554
|
default:
|
|
6567
6555
|
(0, import_internals10.assertNever)(target, "Unknown runtime target");
|
|
6568
6556
|
}
|
|
@@ -6620,7 +6608,7 @@ var import_get_tsconfig = require("get-tsconfig");
|
|
|
6620
6608
|
var import_ts_pattern2 = require("ts-pattern");
|
|
6621
6609
|
|
|
6622
6610
|
// package.json
|
|
6623
|
-
var version = "6.19.0-integration-
|
|
6611
|
+
var version = "6.19.0-integration-next.6";
|
|
6624
6612
|
|
|
6625
6613
|
// src/module-format.ts
|
|
6626
6614
|
function parseModuleFormat(format) {
|
|
@@ -6663,16 +6651,7 @@ function fromTsConfigModule(module2) {
|
|
|
6663
6651
|
}
|
|
6664
6652
|
|
|
6665
6653
|
// src/runtime-targets.ts
|
|
6666
|
-
var supportedPublicRuntimes = [
|
|
6667
|
-
"nodejs",
|
|
6668
|
-
"deno",
|
|
6669
|
-
"bun",
|
|
6670
|
-
"workerd",
|
|
6671
|
-
"cloudflare",
|
|
6672
|
-
"vercel-edge",
|
|
6673
|
-
"edge-light",
|
|
6674
|
-
"react-native"
|
|
6675
|
-
];
|
|
6654
|
+
var supportedPublicRuntimes = ["nodejs", "deno", "bun", "workerd", "cloudflare", "vercel-edge", "edge-light"];
|
|
6676
6655
|
function parseRuntimeTarget(target) {
|
|
6677
6656
|
switch (target.toLowerCase()) {
|
|
6678
6657
|
case "workerd":
|
|
@@ -6686,8 +6665,6 @@ function parseRuntimeTarget(target) {
|
|
|
6686
6665
|
return "nodejs";
|
|
6687
6666
|
case "deno":
|
|
6688
6667
|
return "deno";
|
|
6689
|
-
case "react-native":
|
|
6690
|
-
return "react-native";
|
|
6691
6668
|
default:
|
|
6692
6669
|
throw new Error(
|
|
6693
6670
|
`Unknown target runtime: "${target}". The available options are: ${supportedPublicRuntimes.map((runtime) => `"${runtime}"`).join(", ")}`
|
|
@@ -6761,7 +6738,6 @@ var PrismaClientTsGenerator = class {
|
|
|
6761
6738
|
clientVersion: version,
|
|
6762
6739
|
activeProvider: options.datasources[0]?.activeProvider,
|
|
6763
6740
|
postinstall: options.postinstall,
|
|
6764
|
-
copyEngine: !options.noEngine,
|
|
6765
6741
|
typedSql: options.typedSql,
|
|
6766
6742
|
target,
|
|
6767
6743
|
generatedFileExtension,
|
package/dist/index.mjs
CHANGED
|
@@ -2381,7 +2381,7 @@ var Enum = class {
|
|
|
2381
2381
|
toTS() {
|
|
2382
2382
|
const { type } = this;
|
|
2383
2383
|
const enumVariants = `{
|
|
2384
|
-
${indent(type.
|
|
2384
|
+
${indent(type.data.map((v) => `${v.key}: ${this.getValue(v.value)}`).join(",\n"), TAB_SIZE)}
|
|
2385
2385
|
} as const`;
|
|
2386
2386
|
const enumBody = this.isStrictEnum() ? `runtime.makeStrictEnum(${enumVariants})` : enumVariants;
|
|
2387
2387
|
return `export const ${type.name} = ${enumBody}
|
|
@@ -2935,7 +2935,6 @@ ${modelExports(context).join("\n")}
|
|
|
2935
2935
|
}
|
|
2936
2936
|
|
|
2937
2937
|
// src/TSClient/file-generators/ClassFile.ts
|
|
2938
|
-
import crypto from "node:crypto";
|
|
2939
2938
|
import path2 from "node:path";
|
|
2940
2939
|
import { getClientEngineType as getClientEngineType2, pathToPosix } from "@prisma/internals";
|
|
2941
2940
|
import * as ts6 from "@prisma/ts-builders";
|
|
@@ -3455,7 +3454,7 @@ function escapeJson(str) {
|
|
|
3455
3454
|
function buildRuntimeDataModel(datamodel, runtimeName) {
|
|
3456
3455
|
const runtimeDataModel = dmmfToRuntimeDataModel(datamodel);
|
|
3457
3456
|
let prunedDataModel;
|
|
3458
|
-
if (runtimeName === "wasm-
|
|
3457
|
+
if (runtimeName === "wasm-compiler-edge" || runtimeName === "client") {
|
|
3459
3458
|
prunedDataModel = pruneRuntimeDataModel(runtimeDataModel);
|
|
3460
3459
|
} else {
|
|
3461
3460
|
prunedDataModel = runtimeDataModel;
|
|
@@ -3487,7 +3486,7 @@ import { Debug } from "@prisma/debug";
|
|
|
3487
3486
|
import { match } from "ts-pattern";
|
|
3488
3487
|
var debug = Debug("prisma:client-generator-ts:wasm");
|
|
3489
3488
|
function usesEdgeWasmRuntime(component, runtimeName) {
|
|
3490
|
-
return runtimeName === "wasm-
|
|
3489
|
+
return runtimeName === "wasm-compiler-edge" && component === "compiler";
|
|
3491
3490
|
}
|
|
3492
3491
|
function buildGetWasmModule({
|
|
3493
3492
|
component,
|
|
@@ -3848,7 +3847,6 @@ ${[
|
|
|
3848
3847
|
interactiveTransactionDefinition(this.context),
|
|
3849
3848
|
runCommandRawDefinition(this.context),
|
|
3850
3849
|
metricDefinition(this.context),
|
|
3851
|
-
this.applyPendingMigrationsDefinition(),
|
|
3852
3850
|
extendsPropertyDefinition()
|
|
3853
3851
|
].filter((d) => d !== null).join("\n").trim()}
|
|
3854
3852
|
|
|
@@ -3873,15 +3871,6 @@ get ${methodName}(): Prisma.${m.model}Delegate<${generics.join(", ")}>;`;
|
|
|
3873
3871
|
)}
|
|
3874
3872
|
}`;
|
|
3875
3873
|
}
|
|
3876
|
-
applyPendingMigrationsDefinition() {
|
|
3877
|
-
if (this.runtimeName !== "react-native") {
|
|
3878
|
-
return null;
|
|
3879
|
-
}
|
|
3880
|
-
const method3 = ts5.method("$applyPendingMigrations").setReturnType(promise(ts5.voidType)).setDocComment(
|
|
3881
|
-
ts5.docComment`Tries to apply pending migrations one by one. If a migration fails to apply, the function will stop and throw an error. You are responsible for informing the user and possibly blocking the app as we cannot guarantee the state of the database.`
|
|
3882
|
-
);
|
|
3883
|
-
return ts5.stringify(method3, { indentLevel: 1, newLine: "leading" });
|
|
3884
|
-
}
|
|
3885
3874
|
};
|
|
3886
3875
|
|
|
3887
3876
|
// src/TSClient/file-generators/ClassFile.ts
|
|
@@ -3922,14 +3911,12 @@ function clientConfig(context, options) {
|
|
|
3922
3911
|
runtimeBase,
|
|
3923
3912
|
runtimeName,
|
|
3924
3913
|
datasources,
|
|
3925
|
-
copyEngine = true,
|
|
3926
3914
|
target,
|
|
3927
3915
|
activeProvider,
|
|
3928
3916
|
moduleFormat
|
|
3929
3917
|
} = options;
|
|
3930
3918
|
const clientEngineType = getClientEngineType2(generator);
|
|
3931
3919
|
generator.config.engineType = clientEngineType;
|
|
3932
|
-
const inlineSchemaHash = crypto.createHash("sha256").update(Buffer.from(inlineSchema, "utf8").toString("base64")).digest("hex");
|
|
3933
3920
|
const datasourceFilePath = datasources[0].sourceFilePath;
|
|
3934
3921
|
const config = {
|
|
3935
3922
|
generator,
|
|
@@ -3942,8 +3929,6 @@ function clientConfig(context, options) {
|
|
|
3942
3929
|
ciName: ciInfo.name ?? void 0,
|
|
3943
3930
|
inlineDatasources: buildInlineDatasources(datasources),
|
|
3944
3931
|
inlineSchema,
|
|
3945
|
-
inlineSchemaHash,
|
|
3946
|
-
copyEngine,
|
|
3947
3932
|
runtimeDataModel: { models: {}, enums: {}, types: {} },
|
|
3948
3933
|
dirname: ""
|
|
3949
3934
|
};
|
|
@@ -4050,7 +4035,7 @@ ${imports.join("\n")}
|
|
|
4050
4035
|
${exports.join("\n")}
|
|
4051
4036
|
export { Prisma }
|
|
4052
4037
|
|
|
4053
|
-
${buildNFTAnnotations(options.edge
|
|
4038
|
+
${buildNFTAnnotations(options.edge, clientEngineType, binaryTargets, relativeOutdir)}
|
|
4054
4039
|
|
|
4055
4040
|
${modelExports(context).join("\n")}
|
|
4056
4041
|
`;
|
|
@@ -5152,33 +5137,36 @@ function createModelsFile(context, modelsNames) {
|
|
|
5152
5137
|
}
|
|
5153
5138
|
|
|
5154
5139
|
// src/TSClient/file-generators/PrismaNamespaceBrowserFile.ts
|
|
5140
|
+
import { datamodelSchemaEnumToSchemaEnum } from "@prisma/dmmf";
|
|
5155
5141
|
import * as ts16 from "@prisma/ts-builders";
|
|
5156
5142
|
|
|
5157
5143
|
// src/TSClient/NullTypes.ts
|
|
5158
5144
|
var nullTypes = `
|
|
5159
5145
|
export const NullTypes = {
|
|
5160
|
-
DbNull: runtime.
|
|
5161
|
-
JsonNull: runtime.
|
|
5162
|
-
AnyNull: runtime.
|
|
5146
|
+
DbNull: runtime.NullTypes.DbNull as (new (secret: never) => typeof runtime.DbNull),
|
|
5147
|
+
JsonNull: runtime.NullTypes.JsonNull as (new (secret: never) => typeof runtime.JsonNull),
|
|
5148
|
+
AnyNull: runtime.NullTypes.AnyNull as (new (secret: never) => typeof runtime.AnyNull),
|
|
5163
5149
|
}
|
|
5164
5150
|
/**
|
|
5165
5151
|
* Helper for filtering JSON entries that have \`null\` on the database (empty on the db)
|
|
5166
5152
|
*
|
|
5167
5153
|
* @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
|
|
5168
5154
|
*/
|
|
5169
|
-
export const DbNull = runtime.
|
|
5155
|
+
export const DbNull = runtime.DbNull
|
|
5156
|
+
|
|
5170
5157
|
/**
|
|
5171
5158
|
* Helper for filtering JSON entries that have JSON \`null\` values (not empty on the db)
|
|
5172
5159
|
*
|
|
5173
5160
|
* @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
|
|
5174
5161
|
*/
|
|
5175
|
-
export const JsonNull = runtime.
|
|
5162
|
+
export const JsonNull = runtime.JsonNull
|
|
5163
|
+
|
|
5176
5164
|
/**
|
|
5177
5165
|
* Helper for filtering JSON entries that are \`Prisma.DbNull\` or \`Prisma.JsonNull\`
|
|
5178
5166
|
*
|
|
5179
5167
|
* @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
|
|
5180
5168
|
*/
|
|
5181
|
-
export const AnyNull = runtime.
|
|
5169
|
+
export const AnyNull = runtime.AnyNull
|
|
5182
5170
|
`;
|
|
5183
5171
|
|
|
5184
5172
|
// src/TSClient/file-generators/PrismaNamespaceBrowserFile.ts
|
|
@@ -5195,7 +5183,9 @@ var jsDocHeader7 = `/*
|
|
|
5195
5183
|
*/
|
|
5196
5184
|
`;
|
|
5197
5185
|
function createPrismaNamespaceBrowserFile(context) {
|
|
5198
|
-
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5186
|
+
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5187
|
+
(datamodelEnum) => new Enum(datamodelSchemaEnumToSchemaEnum(datamodelEnum), false).toTS()
|
|
5188
|
+
);
|
|
5199
5189
|
return `${jsDocHeader7}
|
|
5200
5190
|
${ts16.stringify(ts16.moduleImport(`${context.runtimeBase}/index-browser`).asNamespace("runtime"))}
|
|
5201
5191
|
|
|
@@ -5209,7 +5199,10 @@ ${nullTypes}
|
|
|
5209
5199
|
${new Enum(
|
|
5210
5200
|
{
|
|
5211
5201
|
name: "ModelName",
|
|
5212
|
-
|
|
5202
|
+
data: context.dmmf.mappings.modelOperations.map((m) => ({
|
|
5203
|
+
key: m.model,
|
|
5204
|
+
value: m.model
|
|
5205
|
+
}))
|
|
5213
5206
|
},
|
|
5214
5207
|
true
|
|
5215
5208
|
).toTS()}
|
|
@@ -5222,6 +5215,7 @@ ${prismaEnums?.join("\n\n")}
|
|
|
5222
5215
|
}
|
|
5223
5216
|
|
|
5224
5217
|
// src/TSClient/file-generators/PrismaNamespaceFile.ts
|
|
5218
|
+
import { datamodelSchemaEnumToSchemaEnum as datamodelSchemaEnumToSchemaEnum2 } from "@prisma/dmmf";
|
|
5225
5219
|
import * as ts19 from "@prisma/ts-builders";
|
|
5226
5220
|
|
|
5227
5221
|
// src/TSClient/common.ts
|
|
@@ -5761,7 +5755,9 @@ function createPrismaNamespaceFile(context, options) {
|
|
|
5761
5755
|
ts19.moduleImport(context.importFileName(`../models`)).asNamespace("Prisma").typeOnly(),
|
|
5762
5756
|
ts19.moduleImport(context.importFileName(`./class`)).named(ts19.namedImport("PrismaClient").typeOnly())
|
|
5763
5757
|
].map((i) => ts19.stringify(i));
|
|
5764
|
-
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5758
|
+
const prismaEnums = context.dmmf.schema.enumTypes.prisma?.map(
|
|
5759
|
+
(type) => new Enum(datamodelSchemaEnumToSchemaEnum2(type), true).toTS()
|
|
5760
|
+
);
|
|
5765
5761
|
const fieldRefs = context.dmmf.schema.fieldRefTypes.prisma?.map((type) => new FieldRefInput(type).toTS()) ?? [];
|
|
5766
5762
|
return `${jsDocHeader8}
|
|
5767
5763
|
${imports.join("\n")}
|
|
@@ -5772,7 +5768,10 @@ ${commonCodeTS(options)}
|
|
|
5772
5768
|
${new Enum(
|
|
5773
5769
|
{
|
|
5774
5770
|
name: "ModelName",
|
|
5775
|
-
|
|
5771
|
+
data: context.dmmf.mappings.modelOperations.map((m) => ({
|
|
5772
|
+
key: m.model,
|
|
5773
|
+
value: m.model
|
|
5774
|
+
}))
|
|
5776
5775
|
},
|
|
5777
5776
|
true
|
|
5778
5777
|
).toTS()}
|
|
@@ -5882,8 +5881,6 @@ function clientExtensionsDefinitions() {
|
|
|
5882
5881
|
function buildClientOptions(context, options) {
|
|
5883
5882
|
const clientOptions = ts19.interfaceDeclaration("PrismaClientOptions").add(
|
|
5884
5883
|
ts19.property("datasources", ts19.namedType("Datasources")).optional().setDocComment(ts19.docComment("Overwrites the datasource url from your schema.prisma file"))
|
|
5885
|
-
).add(
|
|
5886
|
-
ts19.property("datasourceUrl", ts19.stringType).optional().setDocComment(ts19.docComment("Overwrites the datasource url from your schema.prisma file"))
|
|
5887
5884
|
).add(
|
|
5888
5885
|
ts19.property("errorFormat", ts19.namedType("ErrorFormat")).optional().setDocComment(ts19.docComment('@default "colorless"'))
|
|
5889
5886
|
).add(
|
|
@@ -5923,7 +5920,7 @@ function buildClientOptions(context, options) {
|
|
|
5923
5920
|
timeout ?= 5000
|
|
5924
5921
|
`)
|
|
5925
5922
|
);
|
|
5926
|
-
if (["library", "client", "wasm-compiler-edge"
|
|
5923
|
+
if (["library", "client", "wasm-compiler-edge"].includes(options.runtimeName)) {
|
|
5927
5924
|
clientOptions.add(
|
|
5928
5925
|
ts19.property("adapter", ts19.unionType([ts19.namedType("runtime.SqlDriverAdapterFactory"), ts19.namedType("null")])).optional().setDocComment(
|
|
5929
5926
|
ts19.docComment("Instance of a Driver Adapter, e.g., like one provided by `@prisma/adapter-planetscale`")
|
|
@@ -6291,7 +6288,6 @@ function buildClient({
|
|
|
6291
6288
|
clientVersion,
|
|
6292
6289
|
activeProvider,
|
|
6293
6290
|
postinstall,
|
|
6294
|
-
copyEngine,
|
|
6295
6291
|
envPaths,
|
|
6296
6292
|
typedSql,
|
|
6297
6293
|
target,
|
|
@@ -6317,9 +6313,8 @@ function buildClient({
|
|
|
6317
6313
|
engineVersion,
|
|
6318
6314
|
activeProvider,
|
|
6319
6315
|
postinstall,
|
|
6320
|
-
copyEngine,
|
|
6321
6316
|
datamodel,
|
|
6322
|
-
edge: ["
|
|
6317
|
+
edge: ["wasm-compiler-edge"].includes(runtimeName),
|
|
6323
6318
|
runtimeName,
|
|
6324
6319
|
target,
|
|
6325
6320
|
generatedFileExtension,
|
|
@@ -6327,9 +6322,6 @@ function buildClient({
|
|
|
6327
6322
|
moduleFormat,
|
|
6328
6323
|
tsNoCheckPreamble: tsNoCheckPreamble2
|
|
6329
6324
|
};
|
|
6330
|
-
if (runtimeName === "react-native" && !generator.previewFeatures.includes("reactNative")) {
|
|
6331
|
-
throw new Error(`Using the "react-native" runtime requires the "reactNative" preview feature to be enabled.`);
|
|
6332
|
-
}
|
|
6333
6325
|
const client = new TSClient(clientOptions);
|
|
6334
6326
|
let fileMap = client.generateClientFiles();
|
|
6335
6327
|
if (typedSql && typedSql.length > 0) {
|
|
@@ -6385,7 +6377,6 @@ async function generateClient(options) {
|
|
|
6385
6377
|
activeProvider,
|
|
6386
6378
|
postinstall,
|
|
6387
6379
|
envPaths,
|
|
6388
|
-
copyEngine = true,
|
|
6389
6380
|
typedSql,
|
|
6390
6381
|
target,
|
|
6391
6382
|
generatedFileExtension,
|
|
@@ -6408,7 +6399,6 @@ async function generateClient(options) {
|
|
|
6408
6399
|
engineVersion,
|
|
6409
6400
|
activeProvider,
|
|
6410
6401
|
postinstall,
|
|
6411
|
-
copyEngine,
|
|
6412
6402
|
envPaths,
|
|
6413
6403
|
typedSql,
|
|
6414
6404
|
target,
|
|
@@ -6434,7 +6424,7 @@ To learn more about how to rename models, check out https://pris.ly/d/naming-mod
|
|
|
6434
6424
|
await (0, import_fs_extra.ensureDir)(outputDir);
|
|
6435
6425
|
await writeFileMap(outputDir, fileMap);
|
|
6436
6426
|
const enginePath = clientEngineType === ClientEngineType3.Library ? binaryPaths.libqueryEngine : binaryPaths.queryEngine;
|
|
6437
|
-
if (
|
|
6427
|
+
if (enginePath) {
|
|
6438
6428
|
if (process.env.NETLIFY) {
|
|
6439
6429
|
await (0, import_fs_extra.ensureDir)("/tmp/prisma-engines");
|
|
6440
6430
|
}
|
|
@@ -6559,9 +6549,7 @@ function getRuntimeNameForTarget(target, engineType) {
|
|
|
6559
6549
|
return getNodeRuntimeName(engineType);
|
|
6560
6550
|
case "workerd":
|
|
6561
6551
|
case "vercel-edge":
|
|
6562
|
-
return
|
|
6563
|
-
case "react-native":
|
|
6564
|
-
return "react-native";
|
|
6552
|
+
return "wasm-compiler-edge";
|
|
6565
6553
|
default:
|
|
6566
6554
|
assertNever3(target, "Unknown runtime target");
|
|
6567
6555
|
}
|
|
@@ -6619,7 +6607,7 @@ import { getTsconfig } from "get-tsconfig";
|
|
|
6619
6607
|
import { match as match2 } from "ts-pattern";
|
|
6620
6608
|
|
|
6621
6609
|
// package.json
|
|
6622
|
-
var version = "6.19.0-integration-
|
|
6610
|
+
var version = "6.19.0-integration-next.6";
|
|
6623
6611
|
|
|
6624
6612
|
// src/module-format.ts
|
|
6625
6613
|
function parseModuleFormat(format) {
|
|
@@ -6662,16 +6650,7 @@ function fromTsConfigModule(module) {
|
|
|
6662
6650
|
}
|
|
6663
6651
|
|
|
6664
6652
|
// src/runtime-targets.ts
|
|
6665
|
-
var supportedPublicRuntimes = [
|
|
6666
|
-
"nodejs",
|
|
6667
|
-
"deno",
|
|
6668
|
-
"bun",
|
|
6669
|
-
"workerd",
|
|
6670
|
-
"cloudflare",
|
|
6671
|
-
"vercel-edge",
|
|
6672
|
-
"edge-light",
|
|
6673
|
-
"react-native"
|
|
6674
|
-
];
|
|
6653
|
+
var supportedPublicRuntimes = ["nodejs", "deno", "bun", "workerd", "cloudflare", "vercel-edge", "edge-light"];
|
|
6675
6654
|
function parseRuntimeTarget(target) {
|
|
6676
6655
|
switch (target.toLowerCase()) {
|
|
6677
6656
|
case "workerd":
|
|
@@ -6685,8 +6664,6 @@ function parseRuntimeTarget(target) {
|
|
|
6685
6664
|
return "nodejs";
|
|
6686
6665
|
case "deno":
|
|
6687
6666
|
return "deno";
|
|
6688
|
-
case "react-native":
|
|
6689
|
-
return "react-native";
|
|
6690
6667
|
default:
|
|
6691
6668
|
throw new Error(
|
|
6692
6669
|
`Unknown target runtime: "${target}". The available options are: ${supportedPublicRuntimes.map((runtime) => `"${runtime}"`).join(", ")}`
|
|
@@ -6760,7 +6737,6 @@ var PrismaClientTsGenerator = class {
|
|
|
6760
6737
|
clientVersion: version,
|
|
6761
6738
|
activeProvider: options.datasources[0]?.activeProvider,
|
|
6762
6739
|
postinstall: options.postinstall,
|
|
6763
|
-
copyEngine: !options.noEngine,
|
|
6764
6740
|
typedSql: options.typedSql,
|
|
6765
6741
|
target,
|
|
6766
6742
|
generatedFileExtension,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export declare const supportedInternalRuntimes: readonly ["nodejs", "workerd", "vercel-edge", "deno"
|
|
2
|
-
declare const supportedPublicRuntimes: readonly ["nodejs", "deno", "bun", "workerd", "cloudflare", "vercel-edge", "edge-light"
|
|
1
|
+
export declare const supportedInternalRuntimes: readonly ["nodejs", "workerd", "vercel-edge", "deno"];
|
|
2
|
+
declare const supportedPublicRuntimes: readonly ["nodejs", "deno", "bun", "workerd", "cloudflare", "vercel-edge", "edge-light"];
|
|
3
3
|
/**
|
|
4
4
|
* The user-facing `runtime` attribute for the `prisma-client` generator.
|
|
5
5
|
*/
|
|
@@ -8,5 +8,5 @@ export type RuntimeTarget = (typeof supportedPublicRuntimes)[number];
|
|
|
8
8
|
* The internal representation of the `runtime` attribute for the `prisma-client` generator.
|
|
9
9
|
*/
|
|
10
10
|
export type RuntimeTargetInternal = (typeof supportedInternalRuntimes)[number];
|
|
11
|
-
export declare function parseRuntimeTargetFromUnknown(target: unknown): "nodejs" | "workerd" | "vercel-edge" | "deno"
|
|
11
|
+
export declare function parseRuntimeTargetFromUnknown(target: unknown): "nodejs" | "workerd" | "vercel-edge" | "deno";
|
|
12
12
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma/client-generator-ts",
|
|
3
|
-
"version": "6.19.0-integration-
|
|
3
|
+
"version": "6.19.0-integration-next.6",
|
|
4
4
|
"description": "This package is intended for Prisma's internal use",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"license": "Apache-2.0",
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@antfu/ni": "0.21.12",
|
|
28
|
-
"@prisma/engines-version": "6.
|
|
28
|
+
"@prisma/engines-version": "6.18.0-8.34b5a692b7bd79939a9a2c3ef97d816e749cda2f",
|
|
29
29
|
"ci-info": "4.2.0",
|
|
30
30
|
"fast-glob": "3.3.3",
|
|
31
31
|
"get-tsconfig": "4.10.0",
|
|
@@ -34,14 +34,14 @@
|
|
|
34
34
|
"package-up": "5.0.0",
|
|
35
35
|
"pluralize": "8.0.0",
|
|
36
36
|
"ts-pattern": "5.6.2",
|
|
37
|
-
"@prisma/client-common": "6.19.0-integration-
|
|
38
|
-
"@prisma/
|
|
39
|
-
"@prisma/
|
|
40
|
-
"@prisma/
|
|
41
|
-
"@prisma/
|
|
42
|
-
"@prisma/
|
|
43
|
-
"@prisma/internals": "6.19.0-integration-
|
|
44
|
-
"@prisma/ts-builders": "6.19.0-integration-
|
|
37
|
+
"@prisma/client-common": "6.19.0-integration-next.6",
|
|
38
|
+
"@prisma/dmmf": "6.19.0-integration-next.6",
|
|
39
|
+
"@prisma/debug": "6.19.0-integration-next.6",
|
|
40
|
+
"@prisma/fetch-engine": "6.19.0-integration-next.6",
|
|
41
|
+
"@prisma/get-platform": "6.19.0-integration-next.6",
|
|
42
|
+
"@prisma/generator": "6.19.0-integration-next.6",
|
|
43
|
+
"@prisma/internals": "6.19.0-integration-next.6",
|
|
44
|
+
"@prisma/ts-builders": "6.19.0-integration-next.6"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@types/pluralize": "0.0.33",
|