@prisma/config 6.17.0-dev.30 → 6.17.0-dev.31
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/index.d.ts +4 -0
- package/dist/index.js +22 -2
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -151,6 +151,10 @@ declare type ExperimentalConfig = {
|
|
|
151
151
|
* Enable experimental external tables support.
|
|
152
152
|
*/
|
|
153
153
|
externalTables?: boolean;
|
|
154
|
+
/**
|
|
155
|
+
* Enable experimental extensions support. This is required to use the `extensions` config option.
|
|
156
|
+
*/
|
|
157
|
+
extensions?: boolean;
|
|
154
158
|
};
|
|
155
159
|
|
|
156
160
|
export declare type InjectFormatters = {
|
package/dist/index.js
CHANGED
|
@@ -385,6 +385,11 @@ function validateExperimentalFeatures(config) {
|
|
|
385
385
|
)
|
|
386
386
|
);
|
|
387
387
|
}
|
|
388
|
+
if (config["extensions"] !== void 0 && !experimental.extensions) {
|
|
389
|
+
return import_effect.Either.left(
|
|
390
|
+
new Error("The `extensions` configuration requires `experimental.extensions` to be set to `true`.")
|
|
391
|
+
);
|
|
392
|
+
}
|
|
388
393
|
return import_effect.Either.right(config);
|
|
389
394
|
}
|
|
390
395
|
var debug2 = Debug("prisma:config:defineConfig");
|
|
@@ -404,6 +409,7 @@ function defineConfig(configInput) {
|
|
|
404
409
|
defineEnumsConfig(config, configInput);
|
|
405
410
|
defineTypedSqlConfig(config, configInput);
|
|
406
411
|
defineViewsConfig(config, configInput);
|
|
412
|
+
defineExtensionsConfig(config, configInput);
|
|
407
413
|
return config;
|
|
408
414
|
}
|
|
409
415
|
function defineExperimentalConfig(config, configInput) {
|
|
@@ -481,6 +487,13 @@ function defineAdapterConfig(config, configInput) {
|
|
|
481
487
|
};
|
|
482
488
|
debug2("[config.adapter]: %o", config.adapter);
|
|
483
489
|
}
|
|
490
|
+
function defineExtensionsConfig(config, configInput) {
|
|
491
|
+
if (!configInput["extensions"]) {
|
|
492
|
+
return;
|
|
493
|
+
}
|
|
494
|
+
config["extensions"] = configInput["extensions"];
|
|
495
|
+
debug2("[config.extensions]: %o", config["extensions"]);
|
|
496
|
+
}
|
|
484
497
|
|
|
485
498
|
// src/loadConfigFromPackageJson.ts
|
|
486
499
|
var import_promises = require("node:fs/promises");
|
|
@@ -535,7 +548,8 @@ var ErrorCapturingSqlMigrationAwareDriverAdapterFactoryShape = import_effect3.Sc
|
|
|
535
548
|
var ExperimentalConfigShape = import_effect3.Schema.Struct({
|
|
536
549
|
adapter: import_effect3.Schema.optional(import_effect3.Schema.Boolean),
|
|
537
550
|
studio: import_effect3.Schema.optional(import_effect3.Schema.Boolean),
|
|
538
|
-
externalTables: import_effect3.Schema.optional(import_effect3.Schema.Boolean)
|
|
551
|
+
externalTables: import_effect3.Schema.optional(import_effect3.Schema.Boolean),
|
|
552
|
+
extensions: import_effect3.Schema.optional(import_effect3.Schema.Boolean)
|
|
539
553
|
});
|
|
540
554
|
if (false) {
|
|
541
555
|
__testExperimentalConfigShapeValueA;
|
|
@@ -601,7 +615,8 @@ var PrismaConfigShape = import_effect3.Schema.Struct({
|
|
|
601
615
|
tables: import_effect3.Schema.optional(TablesConfigShape),
|
|
602
616
|
enums: import_effect3.Schema.optional(EnumsConfigShape),
|
|
603
617
|
views: import_effect3.Schema.optional(ViewsConfigShape),
|
|
604
|
-
typedSql: import_effect3.Schema.optional(TypedSqlConfigShape)
|
|
618
|
+
typedSql: import_effect3.Schema.optional(TypedSqlConfigShape),
|
|
619
|
+
extensions: import_effect3.Schema.optional(import_effect3.Schema.Any)
|
|
605
620
|
});
|
|
606
621
|
if (false) {
|
|
607
622
|
__testPrismaConfigValueA;
|
|
@@ -632,6 +647,11 @@ function validateExperimentalFeatures2(config) {
|
|
|
632
647
|
)
|
|
633
648
|
);
|
|
634
649
|
}
|
|
650
|
+
if (config["extensions"] && !experimental.extensions) {
|
|
651
|
+
return import_effect3.Either.left(
|
|
652
|
+
new Error("The `extensions` configuration requires `experimental.extensions` to be set to `true`.")
|
|
653
|
+
);
|
|
654
|
+
}
|
|
635
655
|
return import_effect3.Either.right(config);
|
|
636
656
|
}
|
|
637
657
|
function parsePrismaConfigShape(input) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma/config",
|
|
3
|
-
"version": "6.17.0-dev.
|
|
3
|
+
"version": "6.17.0-dev.31",
|
|
4
4
|
"description": "Internal package used to define and read Prisma configuration files",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
21
|
"vitest": "3.2.4",
|
|
22
|
-
"@prisma/driver-adapter-utils": "6.17.0-dev.
|
|
23
|
-
"@prisma/get-platform": "6.17.0-dev.
|
|
22
|
+
"@prisma/driver-adapter-utils": "6.17.0-dev.31",
|
|
23
|
+
"@prisma/get-platform": "6.17.0-dev.31"
|
|
24
24
|
},
|
|
25
25
|
"files": [
|
|
26
26
|
"dist"
|