@kitr/db 0.2.1 → 0.3.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/docs/index.md +4 -4
- package/package.json +2 -2
package/docs/index.md
CHANGED
|
@@ -222,7 +222,7 @@ Outside a request, such as a scheduled [job](/packages/jobs), pass the root app
|
|
|
222
222
|
```ts
|
|
223
223
|
// server/services/revenue.ts
|
|
224
224
|
import { eq, sum } from 'drizzle-orm'
|
|
225
|
-
import type { KitrApp } from 'kitr/app'
|
|
225
|
+
import type { KitrApp } from '@kitr/kitr/app'
|
|
226
226
|
import { useDb } from '@kitr/db'
|
|
227
227
|
import type { AppDb } from '#config/db'
|
|
228
228
|
import { orders } from '#server/db/schema'
|
|
@@ -267,7 +267,7 @@ The provider resolves `connect` during `app.boot()`, so `useDb` is synchronous a
|
|
|
267
267
|
|
|
268
268
|
```ts
|
|
269
269
|
// app/providers/project_stats.ts
|
|
270
|
-
import { defineProvider } from 'kitr/app'
|
|
270
|
+
import { defineProvider } from '@kitr/kitr/app'
|
|
271
271
|
import type { AppDb } from '#config/db'
|
|
272
272
|
import { projects } from '#server/db/schema'
|
|
273
273
|
|
|
@@ -398,7 +398,7 @@ A missing `process.env.DATABASE_URL!` crashes deep inside the driver. Declare it
|
|
|
398
398
|
|
|
399
399
|
```ts
|
|
400
400
|
// app/env.ts
|
|
401
|
-
import { createEnv, env as e } from 'kitr/env'
|
|
401
|
+
import { createEnv, env as e } from '@kitr/kitr/env'
|
|
402
402
|
|
|
403
403
|
export const env = createEnv({
|
|
404
404
|
public: {},
|
|
@@ -525,7 +525,7 @@ Transactions belong to your ORM; call its API on the client from `useDb`:
|
|
|
525
525
|
```ts
|
|
526
526
|
// server/services/checkout.ts
|
|
527
527
|
import { eq } from 'drizzle-orm'
|
|
528
|
-
import type { KitrApp } from 'kitr/app'
|
|
528
|
+
import type { KitrApp } from '@kitr/kitr/app'
|
|
529
529
|
import { useDb } from '@kitr/db'
|
|
530
530
|
import type { AppDb } from '#config/db'
|
|
531
531
|
import { orders, projects } from '#server/db/schema'
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kitr/db",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "@kitr/db: bind any ORM (Drizzle, Prisma, Kysely) as ctx.db with lifecycle hooks. No ORM shipped.",
|
|
5
5
|
"kitr": {
|
|
6
6
|
"name": "db",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"docs"
|
|
44
44
|
],
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@kitr/core": "0.
|
|
46
|
+
"@kitr/core": "0.3.0"
|
|
47
47
|
},
|
|
48
48
|
"peerDependencies": {},
|
|
49
49
|
"devDependencies": {
|