@forestfuture/active-record 0.7.0 → 0.8.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/config-schema.json +6 -2
- package/dist/adapter.d.mts +3 -3
- package/dist/adapter.mjs +5 -4
- package/dist/batch-ReqVoCfa.mjs +9559 -0
- package/dist/cli.d.mts +55 -33
- package/dist/cli.mjs +4 -4
- package/dist/command.mjs +530 -271
- package/dist/d1.d.mts +2 -10
- package/dist/d1.mjs +0 -0
- package/dist/epoch-storage-CDlQZcBB.mjs +988 -0
- package/dist/{for-adapters-t3-LukJQ.d.mts → for-adapters-B0xMP6Dq.d.mts} +8 -6
- package/dist/{for-adapters-D_Iu0gS_.mjs → for-adapters-CfXMGeOu.mjs} +3 -5
- package/dist/{for-adapters-Ch6CoHD4.mjs → for-adapters-DhNV1mWf.mjs} +46 -10
- package/dist/{generated-model-Cnt0Ot9q.mjs → generated-model-g5oWsDKE.mjs} +728 -540
- package/dist/index-BATasvJa.d.mts +241 -0
- package/dist/index.d.mts +4 -3
- package/dist/index.mjs +5 -4
- package/dist/metadata-CzntpYzC.d.mts +182 -0
- package/dist/{plugin-Cyoej7qV.mjs → plugin-wOSILvSB.mjs} +211 -112
- package/dist/{plugin-XOHYndhP.mjs → plugin-x5-d3TSN.mjs} +148 -52
- package/dist/postgresql.d.mts +1 -9
- package/dist/postgresql.mjs +42 -26
- package/dist/src-D56_3odT.mjs +46 -0
- package/dist/{storage-override-CpbkdIqE.mjs → storage-override-n4w1cS_M.mjs} +61 -28
- package/dist/validations-DHDVV8hB.d.mts +1996 -0
- package/llms-full.txt +2354 -363
- package/package.json +1 -1
- package/skills/active-record/SKILL.md +22 -14
- package/dist/adapter-AGKp6wfO.d.mts +0 -1326
- package/dist/batch-BS_WseLf.mjs +0 -4255
- package/dist/epoch-storage-o2aoOH7H.mjs +0 -112
- package/dist/index-CyCJuM96.d.mts +0 -149
- package/dist/src-la_KkjCS.mjs +0 -1
package/dist/d1.d.mts
CHANGED
|
@@ -1,12 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
//#region src/adapters/d1/adapter.d.ts
|
|
1
|
+
import { C as QueryEvent$1, D as SchemaAdapter, O as AnyDatabase, w as QueryListener$1 } from "./validations-DHDVV8hB.mjs";
|
|
2
|
+
import { i as ActiveRecordError } from "./index-BATasvJa.mjs";
|
|
4
3
|
/** The D1 database a generated schema's Models query: `adapter: d1({ binding: "DB" })`. */
|
|
5
4
|
export declare function d1({ binding }: {
|
|
6
5
|
binding: string;
|
|
7
6
|
}): SchemaAdapter;
|
|
8
|
-
//#endregion
|
|
9
|
-
//#region src/adapters/d1/database.d.ts
|
|
10
7
|
/** What `onQuery` hears about a statement: its Model, SQL, bound values, timing, and D1's `meta`. */
|
|
11
8
|
type QueryEvent = QueryEvent$1<D1Meta>;
|
|
12
9
|
/** Hears each statement's `QueryEvent`, with D1's `meta`. */
|
|
@@ -35,14 +32,10 @@ export declare class Database extends AnyDatabase {
|
|
|
35
32
|
bookmark(): D1SessionBookmark | null;
|
|
36
33
|
}
|
|
37
34
|
export declare function connect(binding: D1Database, options?: ConnectOptions): Database;
|
|
38
|
-
//#endregion
|
|
39
|
-
//#region src/adapters/d1/errors.d.ts
|
|
40
35
|
/** `bookmark()` was called on a Database opened without a `session`. */
|
|
41
36
|
export declare class NoSession extends ActiveRecordError {
|
|
42
37
|
name: string;
|
|
43
38
|
}
|
|
44
|
-
//#endregion
|
|
45
|
-
//#region src/adapters/d1/with-session.d.ts
|
|
46
39
|
/** How `withSession` opens the request's Database, and where its bookmark travels. */
|
|
47
40
|
type SessionOptions = Omit<ConnectOptions, "session"> & {
|
|
48
41
|
/** Where a request with no bookmark starts its Session: `"first-unconstrained"` unless set. */
|
|
@@ -64,5 +57,4 @@ type Handler = (db: Database) => Response | Promise<Response>;
|
|
|
64
57
|
*/
|
|
65
58
|
export declare function withSession(request: Request, binding: D1Database, fn: Handler): Promise<Response>;
|
|
66
59
|
export declare function withSession(request: Request, binding: D1Database, options: SessionOptions, fn: Handler): Promise<Response>;
|
|
67
|
-
//#endregion
|
|
68
60
|
export type { ConnectOptions, QueryEvent, QueryListener, SessionOptions };
|
package/dist/d1.mjs
CHANGED
|
Binary file
|