@rvoh/dream 1.8.0 → 1.9.0
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/CHANGELOG.md +227 -0
- package/dist/cjs/src/helpers/cli/SchemaBuilder.js +4 -0
- package/dist/esm/src/helpers/cli/SchemaBuilder.js +4 -0
- package/dist/types/src/helpers/cli/SchemaBuilder.d.ts +2 -1
- package/dist/types/src/types/dream.d.ts +4 -2
- package/dist/types/src/types/dream.ts +23 -7
- package/docs/classes/Benchmark.html +2 -2
- package/docs/classes/CalendarDate.html +2 -2
- package/docs/classes/CheckConstraintViolation.html +3 -3
- package/docs/classes/CliFileWriter.html +2 -2
- package/docs/classes/ColumnOverflow.html +3 -3
- package/docs/classes/CreateOrFindByFailedToCreateAndFind.html +3 -3
- package/docs/classes/DataIncompatibleWithDatabaseField.html +3 -3
- package/docs/classes/DataTypeColumnTypeMismatch.html +3 -3
- package/docs/classes/Decorators.html +19 -19
- package/docs/classes/Dream.html +113 -113
- package/docs/classes/DreamApp.html +4 -4
- package/docs/classes/DreamBin.html +2 -2
- package/docs/classes/DreamCLI.html +4 -4
- package/docs/classes/DreamImporter.html +2 -2
- package/docs/classes/DreamLogos.html +2 -2
- package/docs/classes/DreamMigrationHelpers.html +8 -8
- package/docs/classes/DreamSerializerBuilder.html +8 -8
- 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/KyselyQueryDriver.html +30 -30
- package/docs/classes/MissingSerializersDefinition.html +3 -3
- package/docs/classes/NonLoadedAssociation.html +3 -3
- package/docs/classes/NotNullViolation.html +3 -3
- package/docs/classes/ObjectSerializerBuilder.html +8 -8
- package/docs/classes/PostgresQueryDriver.html +31 -31
- package/docs/classes/Query.html +53 -53
- package/docs/classes/QueryDriverBase.html +29 -29
- package/docs/classes/Range.html +2 -2
- package/docs/classes/RecordNotFound.html +3 -3
- package/docs/classes/ValidationError.html +3 -3
- package/docs/functions/DreamSerializer.html +1 -1
- package/docs/functions/ObjectSerializer.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/cloneDeepSafe.html +1 -1
- package/docs/functions/closeAllDbConnections.html +1 -1
- package/docs/functions/compact.html +1 -1
- package/docs/functions/dreamDbConnections.html +1 -1
- package/docs/functions/dreamPath.html +1 -1
- package/docs/functions/expandStiClasses.html +1 -1
- package/docs/functions/generateDream.html +1 -1
- package/docs/functions/globalClassNameFromFullyQualifiedModelName.html +1 -1
- package/docs/functions/groupBy.html +1 -1
- package/docs/functions/hyphenize.html +1 -1
- package/docs/functions/inferSerializerFromDreamOrViewModel.html +1 -1
- package/docs/functions/inferSerializersFromDreamClassOrViewModelClass.html +1 -1
- package/docs/functions/intersection.html +1 -1
- package/docs/functions/isDreamSerializer.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/normalizeUnicode.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/sortObjectByKey.html +1 -1
- package/docs/functions/sortObjectByValue.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/untypedDb.html +1 -1
- package/docs/functions/validateColumn.html +1 -1
- package/docs/functions/validateTable.html +1 -1
- package/docs/interfaces/BelongsToStatement.html +2 -2
- package/docs/interfaces/DecoratorContext.html +2 -2
- package/docs/interfaces/DreamAppInitOptions.html +2 -2
- package/docs/interfaces/DreamAppOpts.html +2 -2
- package/docs/interfaces/EncryptOptions.html +2 -2
- package/docs/interfaces/InternalAnyTypedSerializerRendersMany.html +2 -2
- package/docs/interfaces/InternalAnyTypedSerializerRendersOne.html +2 -2
- package/docs/interfaces/OpenapiDescription.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/interfaces/SerializerRendererOpts.html +2 -2
- package/docs/types/Camelized.html +1 -1
- package/docs/types/CommonOpenapiSchemaObjectFields.html +1 -1
- package/docs/types/DateTime.html +1 -1
- package/docs/types/DbConnectionType.html +1 -1
- package/docs/types/DbTypes.html +1 -1
- package/docs/types/DreamAppAllowedPackageManagersEnum.html +1 -1
- package/docs/types/DreamAssociationMetadata.html +1 -1
- package/docs/types/DreamAttributes.html +1 -1
- package/docs/types/DreamClassAssociationAndStatement.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/DreamModelSerializerType.html +1 -1
- package/docs/types/DreamOrViewModelClassSerializerKey.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/DreamSerializable.html +1 -1
- package/docs/types/DreamSerializableArray.html +1 -1
- package/docs/types/DreamSerializerKey.html +1 -1
- package/docs/types/DreamSerializers.html +1 -1
- package/docs/types/DreamVirtualColumns.html +1 -1
- package/docs/types/EncryptAlgorithm.html +1 -1
- package/docs/types/HasManyStatement.html +1 -1
- package/docs/types/HasOneStatement.html +1 -1
- package/docs/types/Hyphenized.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/OpenapiPrimitiveBaseTypes.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/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/OpenapiShorthandPrimitiveBaseTypes.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/RoundingPrecision.html +1 -1
- package/docs/types/SerializerCasing.html +1 -1
- package/docs/types/SimpleObjectSerializerType.html +1 -1
- package/docs/types/Snakeified.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/ViewModel.html +1 -1
- package/docs/types/ViewModelClass.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/DreamAppAllowedPackageManagersEnumValues.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 +2 -2
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
## 1.9.0
|
|
2
|
+
|
|
3
|
+
Fix broken param safe type columns so that:
|
|
4
|
+
|
|
5
|
+
1. polymorphic type fields are excluded from param safe types
|
|
6
|
+
2. association names are excluded
|
|
7
|
+
|
|
8
|
+
Bumping minor, since it could introduce breaking changes for those reliant on previous param safe behavior.
|
|
9
|
+
|
|
10
|
+
## 1.8.0
|
|
11
|
+
|
|
12
|
+
- throw ColumnOverflow when saving too long a string / number to a database column
|
|
13
|
+
- make all of these errors extend the same error so Psychic can check a single error type when deciding to return 400
|
|
14
|
+
|
|
15
|
+
## 1.7.3
|
|
16
|
+
|
|
17
|
+
- remove unnecessary token, now that we are open-sourced
|
|
18
|
+
|
|
19
|
+
## 1.7.2
|
|
20
|
+
|
|
21
|
+
- fix issue causing generators to generate invalid uuid primary keys
|
|
22
|
+
|
|
23
|
+
## 1.7.1
|
|
24
|
+
|
|
25
|
+
- fix error when file without default export exists in the models directory hierarchy
|
|
26
|
+
|
|
27
|
+
## 1.7.0
|
|
28
|
+
|
|
29
|
+
- Remove `Dream#isDreamInstance` and `DreamSerializerBuilder/ObjectSerializerBuilder#isSerializer`
|
|
30
|
+
- Export `MissingSerializersDefinition`
|
|
31
|
+
|
|
32
|
+
## 1.6.0
|
|
33
|
+
|
|
34
|
+
- Move sanitization to Psychic so it can sanitize to real unicode representations
|
|
35
|
+
|
|
36
|
+
## 1.5.2
|
|
37
|
+
|
|
38
|
+
- Don't require `openapi` for virtual attributes
|
|
39
|
+
- Fix Sortable with null value in scope column
|
|
40
|
+
- Enable sanitization of serialized attributes
|
|
41
|
+
- Enable `<association>.<column>: null` where statements even when the column can't be null so that queries can be constructed to locate models that don't have a particular association
|
|
42
|
+
|
|
43
|
+
## 1.5.1
|
|
44
|
+
|
|
45
|
+
Add `DreamMigrationHelpers.newTransaction()` to support explicitly starting a new transaction within a migration.
|
|
46
|
+
|
|
47
|
+
## 1.5.0
|
|
48
|
+
|
|
49
|
+
- add support for multiple database connections in a single dream application. To take advantage of this new feature, you can do the following:
|
|
50
|
+
|
|
51
|
+
1. Add a new connection configuration to your conf/dream.ts file, providing it an explicit alternate connection name as the second argument, like so:
|
|
52
|
+
|
|
53
|
+
```ts
|
|
54
|
+
dreamApp.set('db', 'myAlternateConnection', {
|
|
55
|
+
primary: {
|
|
56
|
+
user: AppEnv.string('DB_USER'),
|
|
57
|
+
password: AppEnv.string('DB_PASSWORD', { optional: !AppEnv.isProduction }),
|
|
58
|
+
host: AppEnv.string('DB_HOST', { optional: true }),
|
|
59
|
+
name: AppEnv.string('DB_NAME_2', { optional: true }),
|
|
60
|
+
port: AppEnv.integer('DB_PORT_2', { optional: true }),
|
|
61
|
+
useSsl: false,
|
|
62
|
+
},
|
|
63
|
+
})
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Be sure to add any new environment variables to your .env and .env.test files.
|
|
67
|
+
|
|
68
|
+
2. Run sync
|
|
69
|
+
|
|
70
|
+
```sh
|
|
71
|
+
yarn psy sync
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
3. add a new application model for your new connection, naming it the name of your connection, pascalized, with the string `ApplicationModel` at the end, like so:
|
|
75
|
+
|
|
76
|
+
```ts
|
|
77
|
+
// app/models/MyAlternateConnectionApplicationModel.ts
|
|
78
|
+
|
|
79
|
+
import Dream from '../../../src/Dream.js'
|
|
80
|
+
import { DBClass } from '../../types/db.alternateConnection.js'
|
|
81
|
+
import { connectionTypeConfig, schema } from '../../types/dream.alternateConnection.js'
|
|
82
|
+
import { globalTypeConfig } from '../../types/dream.globals.js'
|
|
83
|
+
|
|
84
|
+
export default class MyAlternateConnectionApplicationModel extends Dream {
|
|
85
|
+
declare public DB: DBClass
|
|
86
|
+
|
|
87
|
+
public override get connectionName() {
|
|
88
|
+
return 'alternateConnection' as const
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
public override get schema(): any {
|
|
92
|
+
return schema
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
public override get connectionTypeConfig() {
|
|
96
|
+
return connectionTypeConfig
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
public override get globalTypeConfig() {
|
|
100
|
+
return globalTypeConfig
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
4. Now you can proceed to generate a model for your new connection, like so:
|
|
106
|
+
|
|
107
|
+
```sh
|
|
108
|
+
yarn psy g:model MyNewModel someField:text --connection-name=myAlternateConnection
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
Dream will automatically read the connectionName and use it to derive the `MyAlternateConnectionApplicationModel` automatically, though if this isn't correct, you will need to manually adjust it.
|
|
112
|
+
|
|
113
|
+
5. Alternate db engine support
|
|
114
|
+
|
|
115
|
+
If you would like to use an alternate db engine, this is also now supported. To do this, you will need to provide a query driver class that extends one of our base query driver classes. As an example, I recommend you take a look at the `MysqlQueryDriver.ts` file housed within the test-app folder of this repo. This class is not ready for production use, but is a good jumping off point for those interested in supporting a different query driver for dream.
|
|
116
|
+
|
|
117
|
+
To utilize this feature, simply provide a different query driver class in your db connection config, like so:
|
|
118
|
+
|
|
119
|
+
```ts
|
|
120
|
+
// conf/dream.ts
|
|
121
|
+
|
|
122
|
+
app.set('db', {
|
|
123
|
+
queryDriverClass: MyCustomQueryDriverClass,
|
|
124
|
+
...
|
|
125
|
+
})
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
## 1.4.2
|
|
129
|
+
|
|
130
|
+
- add ability to set custom import extension, which will be used when generating new files for your application
|
|
131
|
+
|
|
132
|
+
## 1.4.1
|
|
133
|
+
|
|
134
|
+
- cache Dream app earlier in the initialization sequence
|
|
135
|
+
|
|
136
|
+
## 1.4.0
|
|
137
|
+
|
|
138
|
+
- fix `preloadFor` infinite loop when serializers have circular references
|
|
139
|
+
|
|
140
|
+
- generated STI base serializer updated to only include the single type of the particular STI child in the OpenAPI shape for that child
|
|
141
|
+
|
|
142
|
+
- change `primaryKeyValue` from a getter to a method so it can return the correct type even when `primaryKey` has been overridden on a particular Dream model
|
|
143
|
+
|
|
144
|
+
- remove `IdType`, an unnecessary abstraction that caused type inconsistencies
|
|
145
|
+
|
|
146
|
+
- explicitly handle bigint from the database as string
|
|
147
|
+
|
|
148
|
+
## 1.3.3
|
|
149
|
+
|
|
150
|
+
- make `referenceTypeString` public
|
|
151
|
+
|
|
152
|
+
## 1.3.2
|
|
153
|
+
|
|
154
|
+
- restore aliasing in preload/load queries
|
|
155
|
+
|
|
156
|
+
## 1.3.1
|
|
157
|
+
|
|
158
|
+
- throw NotNullViolation when Postgres throws a not null violation
|
|
159
|
+
|
|
160
|
+
- throw CheckViolation when Postgres throws a check violation
|
|
161
|
+
|
|
162
|
+
## 1.3.0
|
|
163
|
+
|
|
164
|
+
- sti-child generator includes check constraint instead of not-null since the column should only be not-null for that STI child (or modified by hand to accommodate more than one STI child)
|
|
165
|
+
|
|
166
|
+
- add `Dream#hasAssociation`
|
|
167
|
+
|
|
168
|
+
- fix preloading associations on other side of a polyorphic belongs-to association so that we don't set an association on a dream model that doesn't define that association
|
|
169
|
+
|
|
170
|
+
- fix preloading association on the other side of a polymorphic belongs-to since the same association name may be defined differently on different models. For example, taskable may be a Chore or a Workout, both of which have an `images` association, but `images` goes through ChoreImage on Chore and through WorkoutImage on Workout
|
|
171
|
+
|
|
172
|
+
- fix preloadFor when a rendersOne/Many renders a polymorphic belongs-to (was only preloading serializer associations for one of the polymorphically associated models)
|
|
173
|
+
|
|
174
|
+
- fix preloadFor when an explicit serializer option is provided to a rendersOne/Many
|
|
175
|
+
|
|
176
|
+
## 1.2.1
|
|
177
|
+
|
|
178
|
+
- Throw DataTypeColumnTypeMismatch when Postgres throws an error attempting to save to a column with a value that can't be cast to the column type.
|
|
179
|
+
|
|
180
|
+
## 1.2.0
|
|
181
|
+
|
|
182
|
+
- Add Dream.lookup, enabling devs to tap into the IOC provided by dream to dodge circular import issues
|
|
183
|
+
|
|
184
|
+
## 1.1.2
|
|
185
|
+
|
|
186
|
+
- CliFileWriter does not raise error if the file we are writing is not in the file system yet.
|
|
187
|
+
|
|
188
|
+
## 1.1.1
|
|
189
|
+
|
|
190
|
+
- Add fs.writeFile options as third argument to CliFileWriter.write, enabling psychic to provide custom flags when writing openapi.json files.
|
|
191
|
+
|
|
192
|
+
## 1.1.0
|
|
193
|
+
|
|
194
|
+
- Remove support for preloadThroughColumns. They were broken, fixing them would be overly complex, and the same effect can be obtained using flatten on a serializer rendersOne
|
|
195
|
+
|
|
196
|
+
## 1.0.6
|
|
197
|
+
|
|
198
|
+
- Fix joining after a through a polymorphic BelongsTo
|
|
199
|
+
association.
|
|
200
|
+
|
|
201
|
+
- Improve join implementation
|
|
202
|
+
|
|
203
|
+
- Disable leftJoinPreload preloadThroughColumns since it doesn't actually work on through associations that resolve to a source that doesn't match the association name (and we were unnecessarily including columns in the leftJoinPreload statement even when there was no `preloadThroughColumns`, thereby bloating the queries unnecessarily)
|
|
204
|
+
|
|
205
|
+
## 1.0.5
|
|
206
|
+
|
|
207
|
+
- Support HasOne/Many through polymorphic BelongsTo (trick is that it uses the associated model from the HasOne/Many to limit the BelongsTo to a single associated class / table)
|
|
208
|
+
|
|
209
|
+
- Fix HasOne/Many through source type
|
|
210
|
+
|
|
211
|
+
- sync process is now fail-safe, leveraging a utility which caches old copies of files before writing to them. If an exception is thrown at any point during the process, dream will revert all files written using the new `CliFileWriter` class
|
|
212
|
+
|
|
213
|
+
## 1.0.4
|
|
214
|
+
|
|
215
|
+
- properly exclude type from `DreamParamSafeColumnNames`
|
|
216
|
+
|
|
217
|
+
## 1.0.3
|
|
218
|
+
|
|
219
|
+
- exclude type from `DreamParamSafeColumnNames`
|
|
220
|
+
|
|
221
|
+
## 1.0.2
|
|
222
|
+
|
|
223
|
+
- stop computing foreign keys in schema builder when building schema for through associations
|
|
224
|
+
|
|
225
|
+
## 1.0.1
|
|
226
|
+
|
|
227
|
+
- [bug] fix preloading STI model via polymporhic association (polymorphic type was being altered to the STI child rather than left as the STI base)
|
|
@@ -145,6 +145,7 @@ ${tableName}: {
|
|
|
145
145
|
return `${associationName}: {
|
|
146
146
|
type: '${associationMetadata.type}',
|
|
147
147
|
foreignKey: ${associationMetadata.foreignKey ? `'${associationMetadata.foreignKey}'` : 'null'},
|
|
148
|
+
foreignKeyTypeColumn: ${associationMetadata.foreignKeyTypeColumn ? `'${associationMetadata.foreignKeyTypeColumn}'` : 'null'},
|
|
148
149
|
tables: ${stringifyArray(associationMetadata.tables)},
|
|
149
150
|
optional: ${associationMetadata.optional},
|
|
150
151
|
requiredOnClauses: ${requiredOnClauses.length === 0 ? 'null' : stringifyArray(requiredOnClauses)},
|
|
@@ -269,6 +270,9 @@ may need to update the table getter in the corresponding Dream.
|
|
|
269
270
|
type: associationMetaData.type,
|
|
270
271
|
polymorphic: associationMetaData.polymorphic,
|
|
271
272
|
foreignKey,
|
|
273
|
+
foreignKeyTypeColumn: associationMetaData.polymorphic
|
|
274
|
+
? associationMetaData?.foreignKeyTypeField?.() || null
|
|
275
|
+
: null,
|
|
272
276
|
optional,
|
|
273
277
|
where,
|
|
274
278
|
};
|
|
@@ -143,6 +143,7 @@ ${tableName}: {
|
|
|
143
143
|
return `${associationName}: {
|
|
144
144
|
type: '${associationMetadata.type}',
|
|
145
145
|
foreignKey: ${associationMetadata.foreignKey ? `'${associationMetadata.foreignKey}'` : 'null'},
|
|
146
|
+
foreignKeyTypeColumn: ${associationMetadata.foreignKeyTypeColumn ? `'${associationMetadata.foreignKeyTypeColumn}'` : 'null'},
|
|
146
147
|
tables: ${stringifyArray(associationMetadata.tables)},
|
|
147
148
|
optional: ${associationMetadata.optional},
|
|
148
149
|
requiredOnClauses: ${requiredOnClauses.length === 0 ? 'null' : stringifyArray(requiredOnClauses)},
|
|
@@ -267,6 +268,9 @@ may need to update the table getter in the corresponding Dream.
|
|
|
267
268
|
type: associationMetaData.type,
|
|
268
269
|
polymorphic: associationMetaData.polymorphic,
|
|
269
270
|
foreignKey,
|
|
271
|
+
foreignKeyTypeColumn: associationMetaData.polymorphic
|
|
272
|
+
? associationMetaData?.foreignKeyTypeField?.() || null
|
|
273
|
+
: null,
|
|
270
274
|
optional,
|
|
271
275
|
where,
|
|
272
276
|
};
|
|
@@ -25,6 +25,7 @@ export interface SchemaBuilderAssociationData {
|
|
|
25
25
|
polymorphic: boolean;
|
|
26
26
|
optional: boolean | null;
|
|
27
27
|
foreignKey: string | null;
|
|
28
|
+
foreignKeyTypeColumn: string | null;
|
|
28
29
|
where: Record<string, string | typeof DreamConst.passthrough | typeof DreamConst.required> | null;
|
|
29
30
|
}
|
|
30
31
|
export interface SchemaBuilderColumnData {
|
|
@@ -32,8 +33,8 @@ export interface SchemaBuilderColumnData {
|
|
|
32
33
|
allowNull: boolean;
|
|
33
34
|
enumType: string | null;
|
|
34
35
|
enumValues: string | null;
|
|
35
|
-
isArray: boolean;
|
|
36
36
|
foreignKey: string | null;
|
|
37
|
+
isArray: boolean;
|
|
37
38
|
}
|
|
38
39
|
export interface SchemaBuilderInformationSchemaRow {
|
|
39
40
|
columnName: string;
|
|
@@ -23,8 +23,10 @@ export interface SortableOptions<T extends Dream> {
|
|
|
23
23
|
export type PrimaryKeyForFind<I extends Dream, PrimaryKeyType extends DreamPrimaryKeyType<I> = DreamPrimaryKeyType<I>> = PrimaryKeyType extends bigint ? bigint | number | string | null | undefined : PrimaryKeyType | string | null | undefined;
|
|
24
24
|
export type DreamColumnNames<DreamInstance extends Dream, DB = DreamInstance['DB'], TableName extends keyof DB = DreamInstance['table'] & keyof DB, Table extends DB[keyof DB] = DB[TableName], AttributeName extends keyof Table & string = keyof Table & string> = AttributeName;
|
|
25
25
|
export type NonJsonDreamColumnNames<DreamInstance extends Dream, Schema extends DreamInstance['schema'] = DreamInstance['schema'], TableName extends DreamInstance['table'] & keyof Schema = DreamInstance['table'] & keyof Schema, AttributeName extends Exclude<Schema[TableName]['nonJsonColumnNames'][number], keyof Dream> & string = Exclude<Schema[TableName]['nonJsonColumnNames'][number], keyof Dream> & string> = AttributeName;
|
|
26
|
-
export type DreamParamSafeColumnNames<DreamInstance extends Dream
|
|
27
|
-
export type
|
|
26
|
+
export type DreamParamSafeColumnNames<DreamInstance extends Dream> = Exclude<keyof UpdateableProperties<DreamInstance>, DreamParamUnsafeColumnNames<DreamInstance>>;
|
|
27
|
+
export type DreamParamUnsafeColumnNames<DreamInstance extends Dream, BelongsToForeignKeys = DreamBelongsToForeignKeys<DreamInstance>, BelongsToForeignKeyTypes = DreamBelongsToForeignKeyTypes<DreamInstance>, AssociationNames = DreamAssociationNames<DreamInstance>> = BelongsToForeignKeys | BelongsToForeignKeyTypes | (DreamInstance['primaryKey' & keyof DreamInstance] extends undefined ? 'id' : DreamInstance['primaryKey' & keyof DreamInstance]) | (DreamInstance['createdAtField' & keyof DreamInstance] extends undefined ? 'createdAt' : DreamInstance['createdAtField' & keyof DreamInstance]) | (DreamInstance['updatedAtField' & keyof DreamInstance] extends undefined ? 'updatedAt' : DreamInstance['updatedAtField' & keyof DreamInstance]) | (DreamInstance['deletedAtField' & keyof DreamInstance] extends undefined ? 'deletedAt' : DreamInstance['deletedAtField' & keyof DreamInstance]) | AssociationNames | 'type';
|
|
28
|
+
export type DreamBelongsToForeignKeyTypes<DreamInstance extends Dream, AssociationSchema = DreamAssociationMetadata<DreamInstance>, BelongsToAssociationSchema = AssociationSchema[keyof DreamBelongsToAssociationMetadata<DreamInstance> & keyof AssociationSchema], BelongsToForeignKeys = Exclude<BelongsToAssociationSchema['foreignKeyTypeColumn' & keyof BelongsToAssociationSchema], null>> = BelongsToForeignKeys;
|
|
29
|
+
export type DreamBelongsToForeignKeys<DreamInstance extends Dream, AssociationSchema = DreamAssociationMetadata<DreamInstance>, BelongsToAssociationSchema = AssociationSchema[keyof DreamBelongsToAssociationMetadata<DreamInstance> & keyof AssociationSchema], BelongsToForeignKeys = Exclude<BelongsToAssociationSchema['foreignKey' & keyof BelongsToAssociationSchema], null>> = BelongsToForeignKeys;
|
|
28
30
|
export type TableColumnNames<DB, TableName extends keyof DB, Table extends DB[keyof DB] = DB[TableName]> = keyof Table & string;
|
|
29
31
|
export type DreamColumn<DreamInstance extends Dream, Column extends keyof Attrs, Attrs = DreamAttributes<DreamInstance>> = Attrs[Column & keyof Attrs];
|
|
30
32
|
export type DreamClassColumn<DreamClass extends typeof Dream, Column extends keyof DreamAttributes<DreamInstance>, DreamInstance extends InstanceType<DreamClass> = InstanceType<DreamClass>> = DreamColumn<DreamInstance, Column>;
|
|
@@ -72,12 +72,19 @@ export type NonJsonDreamColumnNames<
|
|
|
72
72
|
string = Exclude<Schema[TableName]['nonJsonColumnNames'][number], keyof Dream> & string,
|
|
73
73
|
> = AttributeName
|
|
74
74
|
|
|
75
|
-
export type DreamParamSafeColumnNames<
|
|
75
|
+
export type DreamParamSafeColumnNames<DreamInstance extends Dream> = Exclude<
|
|
76
|
+
keyof UpdateableProperties<DreamInstance>,
|
|
77
|
+
DreamParamUnsafeColumnNames<DreamInstance>
|
|
78
|
+
>
|
|
79
|
+
|
|
80
|
+
export type DreamParamUnsafeColumnNames<
|
|
76
81
|
DreamInstance extends Dream,
|
|
77
82
|
BelongsToForeignKeys = DreamBelongsToForeignKeys<DreamInstance>,
|
|
78
|
-
|
|
79
|
-
|
|
83
|
+
BelongsToForeignKeyTypes = DreamBelongsToForeignKeyTypes<DreamInstance>,
|
|
84
|
+
AssociationNames = DreamAssociationNames<DreamInstance>,
|
|
85
|
+
> =
|
|
80
86
|
| BelongsToForeignKeys
|
|
87
|
+
| BelongsToForeignKeyTypes
|
|
81
88
|
| (DreamInstance['primaryKey' & keyof DreamInstance] extends undefined
|
|
82
89
|
? 'id'
|
|
83
90
|
: DreamInstance['primaryKey' & keyof DreamInstance])
|
|
@@ -90,14 +97,23 @@ export type DreamParamSafeColumnNames<
|
|
|
90
97
|
| (DreamInstance['deletedAtField' & keyof DreamInstance] extends undefined
|
|
91
98
|
? 'deletedAt'
|
|
92
99
|
: DreamInstance['deletedAtField' & keyof DreamInstance])
|
|
100
|
+
| AssociationNames
|
|
93
101
|
| 'type'
|
|
94
|
-
|
|
102
|
+
|
|
103
|
+
export type DreamBelongsToForeignKeyTypes<
|
|
104
|
+
DreamInstance extends Dream,
|
|
105
|
+
AssociationSchema = DreamAssociationMetadata<DreamInstance>,
|
|
106
|
+
BelongsToAssociationSchema = AssociationSchema[keyof DreamBelongsToAssociationMetadata<DreamInstance> &
|
|
107
|
+
keyof AssociationSchema],
|
|
108
|
+
BelongsToForeignKeys = Exclude<
|
|
109
|
+
BelongsToAssociationSchema['foreignKeyTypeColumn' & keyof BelongsToAssociationSchema],
|
|
110
|
+
null
|
|
111
|
+
>,
|
|
112
|
+
> = BelongsToForeignKeys
|
|
95
113
|
|
|
96
114
|
export type DreamBelongsToForeignKeys<
|
|
97
115
|
DreamInstance extends Dream,
|
|
98
|
-
|
|
99
|
-
TableSchema = Schema[DreamInstance['table'] & keyof Schema],
|
|
100
|
-
AssociationSchema = TableSchema['associations' & keyof TableSchema],
|
|
116
|
+
AssociationSchema = DreamAssociationMetadata<DreamInstance>,
|
|
101
117
|
BelongsToAssociationSchema = AssociationSchema[keyof DreamBelongsToAssociationMetadata<DreamInstance> &
|
|
102
118
|
keyof AssociationSchema],
|
|
103
119
|
BelongsToForeignKeys = Exclude<
|
|
@@ -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/6a28c2836fdb8b155b186d55eecbeb2f1a01971a/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/6a28c2836fdb8b155b186d55eecbeb2f1a01971a/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/6a28c2836fdb8b155b186d55eecbeb2f1a01971a/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>
|