@rvoh/dream 1.9.4 → 1.10.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.
Files changed (262) hide show
  1. package/dist/cjs/src/Dream.js +61 -2
  2. package/dist/cjs/src/bin/index.js +6 -0
  3. package/dist/cjs/src/cli/index.js +19 -11
  4. package/dist/cjs/src/db/migration-helpers/DreamMigrationHelpers.js +19 -0
  5. package/dist/cjs/src/decorators/field/association/BelongsTo.js +2 -2
  6. package/dist/cjs/src/decorators/field/association/HasMany.js +2 -2
  7. package/dist/cjs/src/decorators/field/association/HasOne.js +2 -2
  8. package/dist/cjs/src/dream/Query.js +4 -1
  9. package/dist/cjs/src/dream/QueryDriver/Base.js +6 -0
  10. package/dist/cjs/src/dream/QueryDriver/Kysely.js +11 -3
  11. package/dist/cjs/src/dream/QueryDriver/helpers/kysely/checkForNeedToBeRunMigrations.js +27 -0
  12. package/dist/cjs/src/dream/QueryDriver/helpers/kysely/migrationFolderPath.js +11 -0
  13. package/dist/cjs/src/dream/QueryDriver/helpers/kysely/runMigration.js +11 -13
  14. package/dist/cjs/src/dream/internal/orderByDirection.js +2 -3
  15. package/dist/cjs/src/dream/internal/undestroyDream.js +2 -2
  16. package/dist/cjs/src/dream-app/index.js +4 -4
  17. package/dist/cjs/src/errors/associations/InvalidComputedForeignKey.js +3 -4
  18. package/dist/cjs/src/helpers/cli/SchemaBuilder.js +30 -23
  19. package/dist/cjs/src/helpers/cli/generateDreamContent.js +7 -5
  20. package/dist/cjs/src/helpers/cli/generateFactoryContent.js +1 -0
  21. package/dist/cjs/src/helpers/cli/generateMigrationContent.js +17 -16
  22. package/dist/cjs/src/helpers/cli/generateSerializerContent.js +3 -3
  23. package/dist/cjs/src/helpers/comparisonKey.js +16 -1
  24. package/dist/cjs/src/helpers/percent.js +10 -0
  25. package/dist/cjs/src/helpers/sort.js +0 -3
  26. package/dist/cjs/src/helpers/sortBy.js +11 -2
  27. package/dist/cjs/src/helpers/uniq.js +5 -8
  28. package/dist/cjs/src/index.js +3 -1
  29. package/dist/esm/src/Dream.js +61 -2
  30. package/dist/esm/src/bin/index.js +6 -0
  31. package/dist/esm/src/cli/index.js +19 -11
  32. package/dist/esm/src/db/migration-helpers/DreamMigrationHelpers.js +19 -0
  33. package/dist/esm/src/decorators/field/association/BelongsTo.js +2 -2
  34. package/dist/esm/src/decorators/field/association/HasMany.js +2 -2
  35. package/dist/esm/src/decorators/field/association/HasOne.js +2 -2
  36. package/dist/esm/src/dream/Query.js +4 -1
  37. package/dist/esm/src/dream/QueryDriver/Base.js +6 -0
  38. package/dist/esm/src/dream/QueryDriver/Kysely.js +12 -4
  39. package/dist/esm/src/dream/QueryDriver/helpers/kysely/checkForNeedToBeRunMigrations.js +24 -0
  40. package/dist/esm/src/dream/QueryDriver/helpers/kysely/migrationFolderPath.js +8 -0
  41. package/dist/esm/src/dream/QueryDriver/helpers/kysely/runMigration.js +3 -5
  42. package/dist/esm/src/dream/internal/orderByDirection.js +2 -3
  43. package/dist/esm/src/dream/internal/undestroyDream.js +2 -2
  44. package/dist/esm/src/dream-app/index.js +4 -4
  45. package/dist/esm/src/errors/associations/InvalidComputedForeignKey.js +3 -4
  46. package/dist/esm/src/helpers/cli/SchemaBuilder.js +30 -23
  47. package/dist/esm/src/helpers/cli/generateDreamContent.js +7 -5
  48. package/dist/esm/src/helpers/cli/generateFactoryContent.js +1 -0
  49. package/dist/esm/src/helpers/cli/generateMigrationContent.js +17 -16
  50. package/dist/esm/src/helpers/cli/generateSerializerContent.js +3 -3
  51. package/dist/esm/src/helpers/comparisonKey.js +16 -1
  52. package/dist/esm/src/helpers/percent.js +7 -0
  53. package/dist/esm/src/helpers/sort.js +0 -3
  54. package/dist/esm/src/helpers/sortBy.js +11 -2
  55. package/dist/esm/src/helpers/uniq.js +5 -8
  56. package/dist/esm/src/index.js +1 -0
  57. package/dist/types/src/Dream.d.ts +46 -4
  58. package/dist/types/src/bin/index.d.ts +1 -0
  59. package/dist/types/src/db/migration-helpers/DreamMigrationHelpers.d.ts +16 -0
  60. package/dist/types/src/decorators/field/sortable/helpers/setPosition.d.ts +1 -1
  61. package/dist/types/src/dream/QueryDriver/Base.d.ts +1 -0
  62. package/dist/types/src/dream/QueryDriver/Kysely.d.ts +3 -2
  63. package/dist/types/src/dream/QueryDriver/helpers/kysely/checkForNeedToBeRunMigrations.d.ts +9 -0
  64. package/dist/types/src/dream/QueryDriver/helpers/kysely/migrationFolderPath.d.ts +1 -0
  65. package/dist/types/src/dream/internal/orderByDirection.d.ts +2 -1
  66. package/dist/types/src/dream-app/index.d.ts +2 -2
  67. package/dist/types/src/helpers/comparisonKey.d.ts +1 -1
  68. package/dist/types/src/helpers/percent.d.ts +2 -0
  69. package/dist/types/src/helpers/sort.d.ts +3 -1
  70. package/dist/types/src/helpers/sortBy.d.ts +4 -0
  71. package/dist/types/src/index.d.ts +1 -0
  72. package/dist/types/src/serializer/builders/DreamSerializerBuilder.d.ts +1 -1
  73. package/dist/types/src/types/associations/belongsTo.d.ts +2 -2
  74. package/dist/types/src/types/associations/belongsTo.ts +2 -2
  75. package/dist/types/src/types/associations/shared.d.ts +2 -2
  76. package/dist/types/src/types/associations/shared.ts +2 -2
  77. package/dist/types/src/types/dream.d.ts +17 -4
  78. package/dist/types/src/types/dream.ts +38 -13
  79. package/dist/types/src/types/serializer.d.ts +1 -1
  80. package/dist/types/src/types/serializer.ts +1 -1
  81. package/dist/types/src/types/variadic.ts +4 -0
  82. package/docs/assets/navigation.js +1 -1
  83. package/docs/assets/search.js +1 -1
  84. package/docs/classes/Benchmark.html +2 -2
  85. package/docs/classes/CalendarDate.html +2 -2
  86. package/docs/classes/CheckConstraintViolation.html +3 -3
  87. package/docs/classes/CliFileWriter.html +2 -2
  88. package/docs/classes/ColumnOverflow.html +3 -3
  89. package/docs/classes/CreateOrFindByFailedToCreateAndFind.html +3 -3
  90. package/docs/classes/DataIncompatibleWithDatabaseField.html +3 -3
  91. package/docs/classes/DataTypeColumnTypeMismatch.html +3 -3
  92. package/docs/classes/Decorators.html +19 -19
  93. package/docs/classes/Dream.html +201 -174
  94. package/docs/classes/DreamApp.html +4 -4
  95. package/docs/classes/DreamBin.html +3 -2
  96. package/docs/classes/DreamCLI.html +4 -4
  97. package/docs/classes/DreamImporter.html +2 -2
  98. package/docs/classes/DreamLogos.html +2 -2
  99. package/docs/classes/DreamMigrationHelpers.html +19 -8
  100. package/docs/classes/DreamSerializerBuilder.html +13 -13
  101. package/docs/classes/DreamTransaction.html +2 -2
  102. package/docs/classes/Encrypt.html +2 -2
  103. package/docs/classes/Env.html +2 -2
  104. package/docs/classes/GlobalNameNotSet.html +3 -3
  105. package/docs/classes/KyselyQueryDriver.html +31 -30
  106. package/docs/classes/MissingSerializersDefinition.html +3 -3
  107. package/docs/classes/NonLoadedAssociation.html +3 -3
  108. package/docs/classes/NotNullViolation.html +3 -3
  109. package/docs/classes/ObjectSerializerBuilder.html +8 -8
  110. package/docs/classes/PostgresQueryDriver.html +32 -31
  111. package/docs/classes/Query.html +53 -53
  112. package/docs/classes/QueryDriverBase.html +30 -29
  113. package/docs/classes/Range.html +2 -2
  114. package/docs/classes/RecordNotFound.html +3 -3
  115. package/docs/classes/ValidationError.html +3 -3
  116. package/docs/functions/DreamSerializer.html +1 -1
  117. package/docs/functions/ObjectSerializer.html +1 -1
  118. package/docs/functions/ReplicaSafe.html +1 -1
  119. package/docs/functions/STI.html +1 -1
  120. package/docs/functions/SoftDelete.html +1 -1
  121. package/docs/functions/camelize.html +1 -1
  122. package/docs/functions/capitalize.html +1 -1
  123. package/docs/functions/cloneDeepSafe.html +1 -1
  124. package/docs/functions/closeAllDbConnections.html +1 -1
  125. package/docs/functions/compact.html +1 -1
  126. package/docs/functions/dreamDbConnections.html +1 -1
  127. package/docs/functions/dreamPath.html +1 -1
  128. package/docs/functions/expandStiClasses.html +1 -1
  129. package/docs/functions/generateDream.html +1 -1
  130. package/docs/functions/globalClassNameFromFullyQualifiedModelName.html +1 -1
  131. package/docs/functions/groupBy.html +1 -1
  132. package/docs/functions/hyphenize.html +1 -1
  133. package/docs/functions/inferSerializerFromDreamOrViewModel.html +1 -1
  134. package/docs/functions/inferSerializersFromDreamClassOrViewModelClass.html +1 -1
  135. package/docs/functions/intersection.html +1 -1
  136. package/docs/functions/isDreamSerializer.html +1 -1
  137. package/docs/functions/isEmpty.html +1 -1
  138. package/docs/functions/loadRepl.html +1 -1
  139. package/docs/functions/lookupClassByGlobalName.html +1 -1
  140. package/docs/functions/normalizeUnicode.html +1 -1
  141. package/docs/functions/pascalize.html +1 -1
  142. package/docs/functions/percent.html +1 -0
  143. package/docs/functions/pgErrorType.html +1 -1
  144. package/docs/functions/range-1.html +1 -1
  145. package/docs/functions/relativeDreamPath.html +1 -1
  146. package/docs/functions/round.html +1 -1
  147. package/docs/functions/serializerNameFromFullyQualifiedModelName.html +1 -1
  148. package/docs/functions/sharedPathPrefix.html +1 -1
  149. package/docs/functions/snakeify.html +1 -1
  150. package/docs/functions/sort.html +1 -1
  151. package/docs/functions/sortBy.html +1 -1
  152. package/docs/functions/sortObjectByKey.html +1 -1
  153. package/docs/functions/sortObjectByValue.html +1 -1
  154. package/docs/functions/standardizeFullyQualifiedModelName.html +1 -1
  155. package/docs/functions/uncapitalize.html +1 -1
  156. package/docs/functions/uniq.html +1 -1
  157. package/docs/functions/untypedDb.html +1 -1
  158. package/docs/functions/validateColumn.html +1 -1
  159. package/docs/functions/validateTable.html +1 -1
  160. package/docs/interfaces/BelongsToStatement.html +2 -2
  161. package/docs/interfaces/DecoratorContext.html +2 -2
  162. package/docs/interfaces/DreamAppInitOptions.html +2 -2
  163. package/docs/interfaces/DreamAppOpts.html +2 -2
  164. package/docs/interfaces/EncryptOptions.html +2 -2
  165. package/docs/interfaces/InternalAnyTypedSerializerRendersMany.html +2 -2
  166. package/docs/interfaces/InternalAnyTypedSerializerRendersOne.html +2 -2
  167. package/docs/interfaces/OpenapiDescription.html +2 -2
  168. package/docs/interfaces/OpenapiSchemaProperties.html +1 -1
  169. package/docs/interfaces/OpenapiSchemaPropertiesShorthand.html +1 -1
  170. package/docs/interfaces/OpenapiTypeFieldObject.html +1 -1
  171. package/docs/interfaces/SerializerRendererOpts.html +2 -2
  172. package/docs/modules.html +1 -0
  173. package/docs/types/Camelized.html +1 -1
  174. package/docs/types/CommonOpenapiSchemaObjectFields.html +1 -1
  175. package/docs/types/DateTime.html +1 -1
  176. package/docs/types/DbConnectionType.html +1 -1
  177. package/docs/types/DbTypes.html +1 -1
  178. package/docs/types/DreamAppAllowedPackageManagersEnum.html +1 -1
  179. package/docs/types/DreamAssociationMetadata.html +1 -1
  180. package/docs/types/DreamAttributes.html +1 -1
  181. package/docs/types/DreamClassAssociationAndStatement.html +1 -1
  182. package/docs/types/DreamClassColumn.html +1 -1
  183. package/docs/types/DreamColumn.html +1 -1
  184. package/docs/types/DreamColumnNames.html +1 -1
  185. package/docs/types/DreamLogLevel.html +1 -1
  186. package/docs/types/DreamLogger.html +1 -1
  187. package/docs/types/DreamModelSerializerType.html +1 -1
  188. package/docs/types/DreamOrViewModelClassSerializerKey.html +1 -1
  189. package/docs/types/DreamOrViewModelSerializerKey.html +1 -1
  190. package/docs/types/DreamParamSafeAttributes.html +1 -1
  191. package/docs/types/DreamParamSafeColumnNames.html +1 -1
  192. package/docs/types/DreamSerializable.html +1 -1
  193. package/docs/types/DreamSerializableArray.html +1 -1
  194. package/docs/types/DreamSerializerKey.html +1 -1
  195. package/docs/types/DreamSerializers.html +1 -1
  196. package/docs/types/DreamVirtualColumns.html +1 -1
  197. package/docs/types/EncryptAlgorithm.html +1 -1
  198. package/docs/types/HasManyStatement.html +1 -1
  199. package/docs/types/HasOneStatement.html +1 -1
  200. package/docs/types/Hyphenized.html +1 -1
  201. package/docs/types/OpenapiAllTypes.html +1 -1
  202. package/docs/types/OpenapiFormats.html +1 -1
  203. package/docs/types/OpenapiNumberFormats.html +1 -1
  204. package/docs/types/OpenapiPrimitiveBaseTypes.html +1 -1
  205. package/docs/types/OpenapiPrimitiveTypes.html +1 -1
  206. package/docs/types/OpenapiSchemaArray.html +1 -1
  207. package/docs/types/OpenapiSchemaArrayShorthand.html +1 -1
  208. package/docs/types/OpenapiSchemaBase.html +1 -1
  209. package/docs/types/OpenapiSchemaBody.html +1 -1
  210. package/docs/types/OpenapiSchemaBodyShorthand.html +1 -1
  211. package/docs/types/OpenapiSchemaCommonFields.html +1 -1
  212. package/docs/types/OpenapiSchemaExpressionAllOf.html +1 -1
  213. package/docs/types/OpenapiSchemaExpressionAnyOf.html +1 -1
  214. package/docs/types/OpenapiSchemaExpressionOneOf.html +1 -1
  215. package/docs/types/OpenapiSchemaExpressionRef.html +1 -1
  216. package/docs/types/OpenapiSchemaExpressionRefSchemaShorthand.html +1 -1
  217. package/docs/types/OpenapiSchemaInteger.html +1 -1
  218. package/docs/types/OpenapiSchemaNull.html +1 -1
  219. package/docs/types/OpenapiSchemaNumber.html +1 -1
  220. package/docs/types/OpenapiSchemaObject.html +1 -1
  221. package/docs/types/OpenapiSchemaObjectAllOf.html +1 -1
  222. package/docs/types/OpenapiSchemaObjectAllOfShorthand.html +1 -1
  223. package/docs/types/OpenapiSchemaObjectAnyOf.html +1 -1
  224. package/docs/types/OpenapiSchemaObjectAnyOfShorthand.html +1 -1
  225. package/docs/types/OpenapiSchemaObjectBase.html +1 -1
  226. package/docs/types/OpenapiSchemaObjectBaseShorthand.html +1 -1
  227. package/docs/types/OpenapiSchemaObjectOneOf.html +1 -1
  228. package/docs/types/OpenapiSchemaObjectOneOfShorthand.html +1 -1
  229. package/docs/types/OpenapiSchemaObjectShorthand.html +1 -1
  230. package/docs/types/OpenapiSchemaPrimitiveGeneric.html +1 -1
  231. package/docs/types/OpenapiSchemaShorthandExpressionAllOf.html +1 -1
  232. package/docs/types/OpenapiSchemaShorthandExpressionAnyOf.html +1 -1
  233. package/docs/types/OpenapiSchemaShorthandExpressionOneOf.html +1 -1
  234. package/docs/types/OpenapiSchemaShorthandExpressionSerializableRef.html +1 -1
  235. package/docs/types/OpenapiSchemaShorthandExpressionSerializerRef.html +1 -1
  236. package/docs/types/OpenapiSchemaShorthandPrimitiveGeneric.html +1 -1
  237. package/docs/types/OpenapiSchemaString.html +1 -1
  238. package/docs/types/OpenapiShorthandAllTypes.html +1 -1
  239. package/docs/types/OpenapiShorthandPrimitiveBaseTypes.html +1 -1
  240. package/docs/types/OpenapiShorthandPrimitiveTypes.html +1 -1
  241. package/docs/types/OpenapiTypeField.html +1 -1
  242. package/docs/types/Pascalized.html +1 -1
  243. package/docs/types/RoundingPrecision.html +1 -1
  244. package/docs/types/SerializerCasing.html +1 -1
  245. package/docs/types/SimpleObjectSerializerType.html +1 -1
  246. package/docs/types/Snakeified.html +1 -1
  247. package/docs/types/UpdateableAssociationProperties.html +1 -1
  248. package/docs/types/UpdateableProperties.html +1 -1
  249. package/docs/types/ValidationType.html +1 -1
  250. package/docs/types/ViewModel.html +1 -1
  251. package/docs/types/ViewModelClass.html +1 -1
  252. package/docs/types/WhereStatementForDream.html +1 -1
  253. package/docs/types/WhereStatementForDreamClass.html +1 -1
  254. package/docs/variables/DateTime-1.html +1 -1
  255. package/docs/variables/DreamAppAllowedPackageManagersEnumValues.html +1 -1
  256. package/docs/variables/DreamConst.html +1 -1
  257. package/docs/variables/TRIGRAM_OPERATORS.html +1 -1
  258. package/docs/variables/openapiPrimitiveTypes-1.html +1 -1
  259. package/docs/variables/openapiShorthandPrimitiveTypes-1.html +1 -1
  260. package/docs/variables/ops.html +1 -1
  261. package/docs/variables/primaryKeyTypes.html +1 -1
  262. package/package.json +5 -5

There are too many changes on this page to be displayed.


The amount of changes on this page would crash your brower.

You can still verify the content by downloading the package file manually.