@rvoh/dream 0.32.1 → 0.32.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/dist/cjs/src/bin/helpers/sync.js +0 -1
- package/dist/cjs/src/bin/index.js +2 -2
- package/dist/cjs/src/db/index.js +0 -1
- package/dist/cjs/src/helpers/db/dropDb.js +1 -1
- package/dist/cjs/src/helpers/loadRepl.js +26 -2
- package/dist/esm/src/bin/helpers/sync.js +0 -1
- package/dist/esm/src/bin/index.js +2 -2
- package/dist/esm/src/db/index.js +0 -1
- package/dist/esm/src/helpers/db/dropDb.js +1 -1
- package/dist/esm/src/helpers/loadRepl.js +26 -2
- package/dist/types/src/bin/helpers/sync.d.ts +0 -1
- package/dist/types/src/bin/index.d.ts +0 -1
- package/dist/types/src/db/index.d.ts +0 -1
- package/dist/types/src/helpers/loadRepl.d.ts +0 -1
- package/docs/classes/Benchmark.html +2 -2
- package/docs/classes/CalendarDate.html +2 -2
- package/docs/classes/CreateOrFindByFailedToCreateAndFind.html +3 -3
- package/docs/classes/Decorators.html +19 -19
- package/docs/classes/Dream.html +126 -126
- package/docs/classes/DreamApplication.html +4 -4
- package/docs/classes/DreamBin.html +2 -2
- package/docs/classes/DreamCLI.html +4 -4
- package/docs/classes/DreamDbConnection.html +2 -2
- package/docs/classes/DreamGlam.html +2 -2
- package/docs/classes/DreamImporter.html +2 -2
- package/docs/classes/DreamMigrationHelpers.html +7 -7
- package/docs/classes/DreamSerializer.html +2 -2
- package/docs/classes/DreamTransaction.html +2 -2
- package/docs/classes/Encrypt.html +2 -2
- package/docs/classes/Env.html +2 -2
- package/docs/classes/GlobalNameNotSet.html +3 -3
- package/docs/classes/NonLoadedAssociation.html +3 -3
- package/docs/classes/Query.html +50 -50
- package/docs/classes/Range.html +2 -2
- package/docs/classes/RecordNotFound.html +3 -3
- package/docs/classes/ValidationError.html +3 -3
- package/docs/functions/Attribute.html +1 -1
- package/docs/functions/RendersMany.html +1 -1
- package/docs/functions/RendersOne.html +1 -1
- package/docs/functions/ReplicaSafe.html +1 -1
- package/docs/functions/STI.html +1 -1
- package/docs/functions/SoftDelete.html +1 -1
- package/docs/functions/camelize.html +1 -1
- package/docs/functions/capitalize.html +1 -1
- package/docs/functions/closeAllDbConnections.html +1 -1
- package/docs/functions/compact.html +1 -1
- package/docs/functions/db.html +1 -1
- package/docs/functions/debug.html +1 -1
- package/docs/functions/dreamDbConnections.html +1 -1
- package/docs/functions/dreamPath.html +1 -1
- package/docs/functions/generateDream.html +1 -1
- package/docs/functions/globalClassNameFromFullyQualifiedModelName.html +1 -1
- package/docs/functions/hyphenize.html +1 -1
- package/docs/functions/inferSerializerFromDreamClassOrViewModelClass.html +1 -1
- package/docs/functions/inferSerializerFromDreamOrViewModel.html +1 -1
- package/docs/functions/isEmpty.html +1 -1
- package/docs/functions/loadRepl.html +1 -1
- package/docs/functions/lookupClassByGlobalName.html +1 -1
- package/docs/functions/pascalize.html +1 -1
- package/docs/functions/pgErrorType.html +1 -1
- package/docs/functions/range-1.html +1 -1
- package/docs/functions/relativeDreamPath.html +1 -1
- package/docs/functions/round.html +1 -1
- package/docs/functions/serializerNameFromFullyQualifiedModelName.html +1 -1
- package/docs/functions/sharedPathPrefix.html +1 -1
- package/docs/functions/snakeify.html +1 -1
- package/docs/functions/sort.html +1 -1
- package/docs/functions/sortBy.html +1 -1
- package/docs/functions/standardizeFullyQualifiedModelName.html +1 -1
- package/docs/functions/uncapitalize.html +1 -1
- package/docs/functions/uniq.html +1 -1
- package/docs/functions/validateColumn.html +1 -1
- package/docs/functions/validateTable.html +1 -1
- package/docs/interfaces/AttributeStatement.html +2 -2
- package/docs/interfaces/DecoratorContext.html +2 -2
- package/docs/interfaces/DreamApplicationInitOptions.html +2 -2
- package/docs/interfaces/DreamApplicationOpts.html +2 -2
- package/docs/interfaces/DreamSerializerAssociationStatement.html +2 -2
- package/docs/interfaces/EncryptOptions.html +2 -2
- package/docs/interfaces/OpenapiSchemaProperties.html +1 -1
- package/docs/interfaces/OpenapiSchemaPropertiesShorthand.html +1 -1
- package/docs/interfaces/OpenapiTypeFieldObject.html +1 -1
- package/docs/types/Camelized.html +1 -1
- package/docs/types/CommonOpenapiSchemaObjectFields.html +1 -1
- package/docs/types/DateTime.html +1 -1
- package/docs/types/DreamAssociationMetadata.html +1 -1
- package/docs/types/DreamAttributes.html +1 -1
- package/docs/types/DreamClassColumn.html +1 -1
- package/docs/types/DreamColumn.html +1 -1
- package/docs/types/DreamColumnNames.html +1 -1
- package/docs/types/DreamLogLevel.html +1 -1
- package/docs/types/DreamLogger.html +1 -1
- package/docs/types/DreamOrViewModelSerializerKey.html +1 -1
- package/docs/types/DreamParamSafeAttributes.html +1 -1
- package/docs/types/DreamParamSafeColumnNames.html +1 -1
- package/docs/types/DreamSerializerKey.html +1 -1
- package/docs/types/DreamSerializers.html +1 -1
- package/docs/types/DreamTableSchema.html +1 -1
- package/docs/types/DreamVirtualColumns.html +1 -1
- package/docs/types/EncryptAlgorithm.html +1 -1
- package/docs/types/Hyphenized.html +1 -1
- package/docs/types/IdType.html +1 -1
- package/docs/types/OpenapiAllTypes.html +1 -1
- package/docs/types/OpenapiFormats.html +1 -1
- package/docs/types/OpenapiNumberFormats.html +1 -1
- package/docs/types/OpenapiPrimitiveTypes.html +1 -1
- package/docs/types/OpenapiSchemaArray.html +1 -1
- package/docs/types/OpenapiSchemaArrayShorthand.html +1 -1
- package/docs/types/OpenapiSchemaBase.html +1 -1
- package/docs/types/OpenapiSchemaBody.html +1 -1
- package/docs/types/OpenapiSchemaBodyShorthand.html +1 -1
- package/docs/types/OpenapiSchemaCommonFields.html +1 -1
- package/docs/types/OpenapiSchemaExpressionAllOf.html +1 -1
- package/docs/types/OpenapiSchemaExpressionAnyOf.html +1 -1
- package/docs/types/OpenapiSchemaExpressionOneOf.html +1 -1
- package/docs/types/OpenapiSchemaExpressionRef.html +1 -1
- package/docs/types/OpenapiSchemaExpressionRefSchemaShorthand.html +1 -1
- package/docs/types/OpenapiSchemaInteger.html +1 -1
- package/docs/types/OpenapiSchemaNull.html +1 -1
- package/docs/types/OpenapiSchemaNumber.html +1 -1
- package/docs/types/OpenapiSchemaObject.html +1 -1
- package/docs/types/OpenapiSchemaObjectAllOf.html +1 -1
- package/docs/types/OpenapiSchemaObjectAllOfShorthand.html +1 -1
- package/docs/types/OpenapiSchemaObjectAnyOf.html +1 -1
- package/docs/types/OpenapiSchemaObjectAnyOfShorthand.html +1 -1
- package/docs/types/OpenapiSchemaObjectBase.html +1 -1
- package/docs/types/OpenapiSchemaObjectBaseShorthand.html +1 -1
- package/docs/types/OpenapiSchemaObjectOneOf.html +1 -1
- package/docs/types/OpenapiSchemaObjectOneOfShorthand.html +1 -1
- package/docs/types/OpenapiSchemaObjectShorthand.html +1 -1
- package/docs/types/OpenapiSchemaPartialSegment.html +1 -1
- package/docs/types/OpenapiSchemaPrimitiveGeneric.html +1 -1
- package/docs/types/OpenapiSchemaShorthandExpressionAllOf.html +1 -1
- package/docs/types/OpenapiSchemaShorthandExpressionAnyOf.html +1 -1
- package/docs/types/OpenapiSchemaShorthandExpressionOneOf.html +1 -1
- package/docs/types/OpenapiSchemaShorthandExpressionSerializableRef.html +1 -1
- package/docs/types/OpenapiSchemaShorthandExpressionSerializerRef.html +1 -1
- package/docs/types/OpenapiSchemaShorthandPrimitiveGeneric.html +1 -1
- package/docs/types/OpenapiSchemaString.html +1 -1
- package/docs/types/OpenapiShorthandAllTypes.html +1 -1
- package/docs/types/OpenapiShorthandPrimitiveTypes.html +1 -1
- package/docs/types/OpenapiTypeField.html +1 -1
- package/docs/types/Pascalized.html +1 -1
- package/docs/types/PrimaryKeyType.html +1 -1
- package/docs/types/RoundingPrecision.html +1 -1
- package/docs/types/SerializableClassOrSerializerCallback.html +1 -1
- package/docs/types/SerializableDreamClassOrViewModelClass.html +1 -1
- package/docs/types/SerializableDreamOrViewModel.html +1 -1
- package/docs/types/SerializableTypes.html +1 -1
- package/docs/types/Snakeified.html +1 -1
- package/docs/types/Timestamp.html +1 -1
- package/docs/types/UpdateableAssociationProperties.html +1 -1
- package/docs/types/UpdateableProperties.html +1 -1
- package/docs/types/ValidationType.html +1 -1
- package/docs/types/ViewModelSerializerKey.html +1 -1
- package/docs/types/WhereStatementForDream.html +1 -1
- package/docs/types/WhereStatementForDreamClass.html +1 -1
- package/docs/variables/DateTime-1.html +1 -1
- package/docs/variables/DreamConst.html +1 -1
- package/docs/variables/TRIGRAM_OPERATORS.html +1 -1
- package/docs/variables/openapiPrimitiveTypes-1.html +1 -1
- package/docs/variables/openapiShorthandPrimitiveTypes-1.html +1 -1
- package/docs/variables/ops.html +1 -1
- package/docs/variables/primaryKeyTypes.html +1 -1
- package/package.json +5 -6
- package/dist/cjs/src/helpers/dreamOrPsychicCoreDevelopment.js +0 -10
- package/dist/cjs/src/helpers/loadEnv.js +0 -37
- package/dist/esm/src/helpers/dreamOrPsychicCoreDevelopment.js +0 -7
- package/dist/esm/src/helpers/loadEnv.js +0 -35
- package/dist/types/src/helpers/dreamOrPsychicCoreDevelopment.d.ts +0 -1
- package/dist/types/src/helpers/loadEnv.d.ts +0 -1
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.default = writeSyncFile;
|
|
4
|
-
require("../../helpers/loadEnv.js");
|
|
5
4
|
const fs = require("fs/promises");
|
|
6
5
|
const path = require("path");
|
|
7
6
|
const index_js_1 = require("../../cli/index.js");
|
|
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
const index_js_1 = require("../cli/index.js");
|
|
4
4
|
const ConnectionConfRetriever_js_1 = require("../db/ConnectionConfRetriever.js");
|
|
5
5
|
const index_js_2 = require("../dream-application/index.js");
|
|
6
|
+
const EnvInternal_js_1 = require("../helpers/EnvInternal.js");
|
|
6
7
|
const SchemaBuilder_js_1 = require("../helpers/cli/SchemaBuilder.js");
|
|
7
8
|
const generateDream_js_1 = require("../helpers/cli/generateDream.js");
|
|
8
9
|
const generateMigration_js_1 = require("../helpers/cli/generateMigration.js");
|
|
@@ -10,7 +11,6 @@ const createDb_js_1 = require("../helpers/db/createDb.js");
|
|
|
10
11
|
const dropDb_js_1 = require("../helpers/db/dropDb.js");
|
|
11
12
|
const loadPgClient_js_1 = require("../helpers/db/loadPgClient.js");
|
|
12
13
|
const runMigration_js_1 = require("../helpers/db/runMigration.js");
|
|
13
|
-
require("../helpers/loadEnv.js");
|
|
14
14
|
const sspawn_js_1 = require("../helpers/sspawn.js");
|
|
15
15
|
const sync_js_1 = require("./helpers/sync.js");
|
|
16
16
|
class DreamBin {
|
|
@@ -102,7 +102,7 @@ class DreamBin {
|
|
|
102
102
|
const connectionRetriever = new ConnectionConfRetriever_js_1.default();
|
|
103
103
|
const dbConf = connectionRetriever.getConnectionConf('primary');
|
|
104
104
|
const client = await (0, loadPgClient_js_1.default)({ useSystemDb: true });
|
|
105
|
-
if (
|
|
105
|
+
if (EnvInternal_js_1.default.boolean('DREAM_CORE_DEVELOPMENT')) {
|
|
106
106
|
const replicaTestWorkerDatabaseName = `replica_test_${dbConf.name}`;
|
|
107
107
|
index_js_1.default.logger.logContinueProgress(`creating fake replica test database ${replicaTestWorkerDatabaseName}...`);
|
|
108
108
|
await client.query(`DROP DATABASE IF EXISTS ${replicaTestWorkerDatabaseName};`);
|
package/dist/cjs/src/db/index.js
CHANGED
|
@@ -3,7 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.default = db;
|
|
4
4
|
const DateTime_js_1 = require("../helpers/DateTime.js");
|
|
5
5
|
const EnvInternal_js_1 = require("../helpers/EnvInternal.js");
|
|
6
|
-
require("../helpers/loadEnv.js");
|
|
7
6
|
const DreamDbConnection_js_1 = require("./DreamDbConnection.js");
|
|
8
7
|
if (EnvInternal_js_1.default.string('TZ', { optional: true }))
|
|
9
8
|
DateTime_js_1.Settings.defaultZone = EnvInternal_js_1.default.string('TZ');
|
|
@@ -23,7 +23,7 @@ async function maybeDropDuplicateDatabases(client, dbName) {
|
|
|
23
23
|
const parallelTests = index_js_1.default.getOrFail().parallelTests;
|
|
24
24
|
if (!parallelTests)
|
|
25
25
|
return;
|
|
26
|
-
if (
|
|
26
|
+
if (EnvInternal_js_1.default.boolean('DREAM_CORE_DEVELOPMENT')) {
|
|
27
27
|
const replicaTestWorkerDatabaseName = `replica_test_${dbName}`;
|
|
28
28
|
console.log(`dropping fake replica test database ${replicaTestWorkerDatabaseName}`);
|
|
29
29
|
await client.query(`DROP DATABASE IF EXISTS ${replicaTestWorkerDatabaseName};`);
|
|
@@ -1,19 +1,43 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.default = loadRepl;
|
|
4
|
-
require("./loadEnv.js");
|
|
5
4
|
const index_js_1 = require("../dream-application/index.js");
|
|
6
5
|
const index_js_2 = require("../encrypt/index.js");
|
|
7
6
|
const index_js_3 = require("../ops/index.js");
|
|
8
7
|
const CalendarDate_js_1 = require("./CalendarDate.js");
|
|
8
|
+
const camelize_js_1 = require("./camelize.js");
|
|
9
|
+
const capitalize_js_1 = require("./capitalize.js");
|
|
10
|
+
const compact_js_1 = require("./compact.js");
|
|
9
11
|
const DateTime_js_1 = require("./DateTime.js");
|
|
12
|
+
const hyphenize_js_1 = require("./hyphenize.js");
|
|
13
|
+
const pascalize_js_1 = require("./pascalize.js");
|
|
10
14
|
const pascalizePath_js_1 = require("./pascalizePath.js");
|
|
15
|
+
const range_js_1 = require("./range.js");
|
|
16
|
+
const round_js_1 = require("./round.js");
|
|
17
|
+
const snakeify_js_1 = require("./snakeify.js");
|
|
18
|
+
const sort_js_1 = require("./sort.js");
|
|
19
|
+
const sortBy_js_1 = require("./sortBy.js");
|
|
20
|
+
const uncapitalize_js_1 = require("./uncapitalize.js");
|
|
21
|
+
const uniq_js_1 = require("./uniq.js");
|
|
11
22
|
function loadRepl(context) {
|
|
12
23
|
const dreamApp = index_js_1.default.getOrFail();
|
|
13
|
-
context.DateTime = DateTime_js_1.DateTime;
|
|
14
24
|
context.CalendarDate = CalendarDate_js_1.default;
|
|
25
|
+
context.DateTime = DateTime_js_1.DateTime;
|
|
15
26
|
context.Encrypt = index_js_2.default;
|
|
27
|
+
context.camelize = camelize_js_1.default;
|
|
28
|
+
context.capitalize = capitalize_js_1.default;
|
|
29
|
+
context.compact = compact_js_1.default;
|
|
30
|
+
context.hyphenize = hyphenize_js_1.default;
|
|
16
31
|
context.ops = index_js_3.default;
|
|
32
|
+
context.pascalize = pascalize_js_1.default;
|
|
33
|
+
context.pascalizePath = pascalizePath_js_1.default;
|
|
34
|
+
context.range = range_js_1.default;
|
|
35
|
+
context.round = round_js_1.default;
|
|
36
|
+
context.snakeify = snakeify_js_1.default;
|
|
37
|
+
context.sort = sort_js_1.default;
|
|
38
|
+
context.sortBy = sortBy_js_1.default;
|
|
39
|
+
context.uncapitalize = uncapitalize_js_1.default;
|
|
40
|
+
context.uniq = uniq_js_1.default;
|
|
17
41
|
for (const globalName of Object.keys(dreamApp.models)) {
|
|
18
42
|
context[(0, pascalizePath_js_1.default)(globalName)] = dreamApp.models[globalName];
|
|
19
43
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import DreamCLI from '../cli/index.js';
|
|
2
2
|
import ConnectionConfRetriever from '../db/ConnectionConfRetriever.js';
|
|
3
3
|
import DreamApplication from '../dream-application/index.js';
|
|
4
|
+
import EnvInternal from '../helpers/EnvInternal.js';
|
|
4
5
|
import SchemaBuilder from '../helpers/cli/SchemaBuilder.js';
|
|
5
6
|
import generateDream from '../helpers/cli/generateDream.js';
|
|
6
7
|
import generateMigration from '../helpers/cli/generateMigration.js';
|
|
@@ -8,7 +9,6 @@ import createDb from '../helpers/db/createDb.js';
|
|
|
8
9
|
import _dropDb from '../helpers/db/dropDb.js';
|
|
9
10
|
import loadPgClient from '../helpers/db/loadPgClient.js';
|
|
10
11
|
import runMigration from '../helpers/db/runMigration.js';
|
|
11
|
-
import '../helpers/loadEnv.js';
|
|
12
12
|
import sspawn from '../helpers/sspawn.js';
|
|
13
13
|
import writeSyncFile from './helpers/sync.js';
|
|
14
14
|
export default class DreamBin {
|
|
@@ -100,7 +100,7 @@ export default class DreamBin {
|
|
|
100
100
|
const connectionRetriever = new ConnectionConfRetriever();
|
|
101
101
|
const dbConf = connectionRetriever.getConnectionConf('primary');
|
|
102
102
|
const client = await loadPgClient({ useSystemDb: true });
|
|
103
|
-
if (
|
|
103
|
+
if (EnvInternal.boolean('DREAM_CORE_DEVELOPMENT')) {
|
|
104
104
|
const replicaTestWorkerDatabaseName = `replica_test_${dbConf.name}`;
|
|
105
105
|
DreamCLI.logger.logContinueProgress(`creating fake replica test database ${replicaTestWorkerDatabaseName}...`);
|
|
106
106
|
await client.query(`DROP DATABASE IF EXISTS ${replicaTestWorkerDatabaseName};`);
|
package/dist/esm/src/db/index.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Settings } from '../helpers/DateTime.js';
|
|
2
2
|
import EnvInternal from '../helpers/EnvInternal.js';
|
|
3
|
-
import '../helpers/loadEnv.js';
|
|
4
3
|
import DreamDbConnection from './DreamDbConnection.js';
|
|
5
4
|
if (EnvInternal.string('TZ', { optional: true }))
|
|
6
5
|
Settings.defaultZone = EnvInternal.string('TZ');
|
|
@@ -20,7 +20,7 @@ async function maybeDropDuplicateDatabases(client, dbName) {
|
|
|
20
20
|
const parallelTests = DreamApplication.getOrFail().parallelTests;
|
|
21
21
|
if (!parallelTests)
|
|
22
22
|
return;
|
|
23
|
-
if (
|
|
23
|
+
if (EnvInternal.boolean('DREAM_CORE_DEVELOPMENT')) {
|
|
24
24
|
const replicaTestWorkerDatabaseName = `replica_test_${dbName}`;
|
|
25
25
|
console.log(`dropping fake replica test database ${replicaTestWorkerDatabaseName}`);
|
|
26
26
|
await client.query(`DROP DATABASE IF EXISTS ${replicaTestWorkerDatabaseName};`);
|
|
@@ -1,16 +1,40 @@
|
|
|
1
|
-
import './loadEnv.js';
|
|
2
1
|
import DreamApplication from '../dream-application/index.js';
|
|
3
2
|
import Encrypt from '../encrypt/index.js';
|
|
4
3
|
import ops from '../ops/index.js';
|
|
5
4
|
import CalendarDate from './CalendarDate.js';
|
|
5
|
+
import camelize from './camelize.js';
|
|
6
|
+
import capitalize from './capitalize.js';
|
|
7
|
+
import compact from './compact.js';
|
|
6
8
|
import { DateTime } from './DateTime.js';
|
|
9
|
+
import hyphenize from './hyphenize.js';
|
|
10
|
+
import pascalize from './pascalize.js';
|
|
7
11
|
import pascalizePath from './pascalizePath.js';
|
|
12
|
+
import range from './range.js';
|
|
13
|
+
import round from './round.js';
|
|
14
|
+
import snakeify from './snakeify.js';
|
|
15
|
+
import sort from './sort.js';
|
|
16
|
+
import sortBy from './sortBy.js';
|
|
17
|
+
import uncapitalize from './uncapitalize.js';
|
|
18
|
+
import uniq from './uniq.js';
|
|
8
19
|
export default function loadRepl(context) {
|
|
9
20
|
const dreamApp = DreamApplication.getOrFail();
|
|
10
|
-
context.DateTime = DateTime;
|
|
11
21
|
context.CalendarDate = CalendarDate;
|
|
22
|
+
context.DateTime = DateTime;
|
|
12
23
|
context.Encrypt = Encrypt;
|
|
24
|
+
context.camelize = camelize;
|
|
25
|
+
context.capitalize = capitalize;
|
|
26
|
+
context.compact = compact;
|
|
27
|
+
context.hyphenize = hyphenize;
|
|
13
28
|
context.ops = ops;
|
|
29
|
+
context.pascalize = pascalize;
|
|
30
|
+
context.pascalizePath = pascalizePath;
|
|
31
|
+
context.range = range;
|
|
32
|
+
context.round = round;
|
|
33
|
+
context.snakeify = snakeify;
|
|
34
|
+
context.sort = sort;
|
|
35
|
+
context.sortBy = sortBy;
|
|
36
|
+
context.uncapitalize = uncapitalize;
|
|
37
|
+
context.uniq = uniq;
|
|
14
38
|
for (const globalName of Object.keys(dreamApp.models)) {
|
|
15
39
|
context[pascalizePath(globalName)] = dreamApp.models[globalName];
|
|
16
40
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { Kysely } from 'kysely';
|
|
2
2
|
import Dream from '../Dream.js';
|
|
3
|
-
import '../helpers/loadEnv.js';
|
|
4
3
|
import { DbConnectionType } from '../types/db.js';
|
|
5
4
|
export default function db<T extends Dream, DB extends T['DB'] = T['DB']>(connectionType?: DbConnectionType): Kysely<DB>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<!DOCTYPE html><html class="default" lang="en"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>Benchmark | @rvoh/dream</title><meta name="description" content="Documentation for @rvoh/dream"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@rvoh/dream</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@rvoh/dream</a></li><li><a href="Benchmark.html">Benchmark</a></li></ul><h1>Class Benchmark</h1></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/rvohealth/dream/blob/
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>Benchmark | @rvoh/dream</title><meta name="description" content="Documentation for @rvoh/dream"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@rvoh/dream</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@rvoh/dream</a></li><li><a href="Benchmark.html">Benchmark</a></li></ul><h1>Class Benchmark</h1></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/rvohealth/dream/blob/3e34725ce70c93a0f8d01fd13804fc702b0a9d10/src/helpers/benchmark.ts#L6">src/helpers/benchmark.ts:6</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><h5 class="tsd-index-heading uppercase" role="button" aria-expanded="false" tabIndex="0"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-chevronSmall"></use></svg> Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Constructors</h3><div class="tsd-index-list"><a href="Benchmark.html#constructor" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a>
|
|
2
2
|
</div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Methods</h3><div class="tsd-index-list"><a href="Benchmark.html#mark" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>mark</span></a>
|
|
3
3
|
<a href="Benchmark.html#start" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>start</span></a>
|
|
4
|
-
</div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg> Constructors</h2></summary><section><section class="tsd-panel tsd-member"><a id="constructor" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class="tsd-signature tsd-anchor-link"><a id="constructor.new_Benchmark" class="tsd-anchor"></a><span class="tsd-kind-constructor-signature">new <wbr/>Benchmark</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="Benchmark.html" class="tsd-signature-type tsd-kind-class">Benchmark</a><a href="#constructor.new_Benchmark" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><h4 class="tsd-returns-title">Returns <a href="Benchmark.html" class="tsd-signature-type tsd-kind-class">Benchmark</a></h4></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg> Methods</h2></summary><section><section class="tsd-panel tsd-member"><a id="mark" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>mark</span><a href="#mark" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class="tsd-signature tsd-anchor-link"><a id="mark.mark-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">mark</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">message</span>, <span class="tsd-kind-parameter">level</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#mark.mark-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">message</span>: <span class="tsd-signature-type">string</span></span></li><li><span><span class="tsd-kind-parameter">level</span>: <span class="tsd-signature-type">BenchmarkLogLevel</span><span class="tsd-signature-symbol"> = 'log'</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/rvohealth/dream/blob/
|
|
4
|
+
</div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Constructors"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg> Constructors</h2></summary><section><section class="tsd-panel tsd-member"><a id="constructor" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>constructor</span><a href="#constructor" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class="tsd-signature tsd-anchor-link"><a id="constructor.new_Benchmark" class="tsd-anchor"></a><span class="tsd-kind-constructor-signature">new <wbr/>Benchmark</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="Benchmark.html" class="tsd-signature-type tsd-kind-class">Benchmark</a><a href="#constructor.new_Benchmark" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><h4 class="tsd-returns-title">Returns <a href="Benchmark.html" class="tsd-signature-type tsd-kind-class">Benchmark</a></h4></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><h2><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg> Methods</h2></summary><section><section class="tsd-panel tsd-member"><a id="mark" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>mark</span><a href="#mark" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class="tsd-signature tsd-anchor-link"><a id="mark.mark-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">mark</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">message</span>, <span class="tsd-kind-parameter">level</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#mark.mark-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">message</span>: <span class="tsd-signature-type">string</span></span></li><li><span><span class="tsd-kind-parameter">level</span>: <span class="tsd-signature-type">BenchmarkLogLevel</span><span class="tsd-signature-symbol"> = 'log'</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/rvohealth/dream/blob/3e34725ce70c93a0f8d01fd13804fc702b0a9d10/src/helpers/benchmark.ts#L12">src/helpers/benchmark.ts:12</a></li></ul></aside></li></ul></section><section class="tsd-panel tsd-member"><a id="start" class="tsd-anchor"></a><h3 class="tsd-anchor-link"><span>start</span><a href="#start" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class="tsd-signature tsd-anchor-link"><a id="start.start-1" class="tsd-anchor"></a><span class="tsd-kind-call-signature">start</span><span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#start.start-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></li><li class="tsd-description"><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/rvohealth/dream/blob/3e34725ce70c93a0f8d01fd13804fc702b0a9d10/src/helpers/benchmark.ts#L8">src/helpers/benchmark.ts:8</a></li></ul></aside></li></ul></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="tsd-otp-Constructors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Constructors</summary><div><a href="#constructor" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-512"></use></svg><span>constructor</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="tsd-otp-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Methods</summary><div><a href="#mark" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>mark</span></a><a href="#start" class=""><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-2048"></use></svg><span>start</span></a></div></details></div></details></div><div class="site-menu"><nav class="tsd-navigation"><a href="../modules.html"><svg class="tsd-kind-icon" viewBox="0 0 24 24"><use href="../assets/icons.svg#icon-1"></use></svg><span>@rvoh/dream</span></a><ul class="tsd-small-nested-navigation" id="tsd-nav-container" data-base=".."><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|