ziex 0.1.0-dev.1387 → 0.1.0-dev.1458
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/README.md +4 -1
- package/app.d.ts +6 -6
- package/build.zig.zon +1 -1
- package/index.js +477 -169
- package/package.json +7 -5
- package/{aws-lambda → platforms/aws-lambda}/index.js +1 -1
- package/platforms/cloudflare/app.d.ts +2 -0
- package/platforms/cloudflare/db.d.ts +6 -0
- package/{cloudflare → platforms/cloudflare}/do.d.ts +5 -5
- package/platforms/cloudflare/index.d.ts +4 -0
- package/{cloudflare → platforms/cloudflare}/index.js +1666 -1293
- package/platforms/cloudflare/kv.d.ts +5 -0
- package/platforms/cloudflare/worker.d.ts +3 -0
- package/{vercel → platforms/vercel}/index.js +1 -1
- package/runtime/db/extern.d.ts +38 -0
- package/runtime/db/sqlite.d.ts +7 -0
- package/runtime/db.d.ts +3 -0
- package/runtime/db.js +419 -0
- package/{fetch.d.ts → runtime/fetch.d.ts} +1 -1
- package/{runtime.d.ts → runtime/index.d.ts} +6 -15
- package/runtime/kv/extern.d.ts +11 -0
- package/runtime/kv/indexdb.d.ts +7 -0
- package/runtime/kv/localstorage.d.ts +6 -0
- package/runtime/kv/memory.d.ts +6 -0
- package/runtime/kv.d.ts +44 -0
- package/runtime/kv.js +542 -0
- package/wasm/core.d.ts +29 -27
- package/wasm/index.d.ts +13 -12
- package/wasm/index.js +431 -240
- package/wasm/init.dev.js +407 -238
- package/wasm/init.js +3 -3
- package/wasm/wasi.d.ts +1 -5
- package/browser/kv.d.ts +0 -13
- package/cloudflare/app.d.ts +0 -2
- package/cloudflare/db.d.ts +0 -2
- package/cloudflare/index.d.ts +0 -4
- package/cloudflare/kv.d.ts +0 -2
- package/cloudflare/worker.d.ts +0 -3
- package/db.d.ts +0 -22
- package/kv.d.ts +0 -42
- /package/{aws-lambda → platforms/aws-lambda}/index.d.ts +0 -0
- /package/{vercel → platforms/vercel}/index.d.ts +0 -0
- /package/{wasi.d.ts → runtime/wasi.d.ts} +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ziex",
|
|
3
|
-
"version": "0.1.0-dev.
|
|
3
|
+
"version": "0.1.0-dev.1458",
|
|
4
4
|
"types": "index.d.ts",
|
|
5
5
|
"description": "Ziex is a framework for building web applications with Zig.",
|
|
6
6
|
"main": "index.js",
|
|
@@ -13,9 +13,11 @@
|
|
|
13
13
|
"./jsx": "./jsx/index.js",
|
|
14
14
|
"./wasm": "./wasm/index.js",
|
|
15
15
|
"./wasm/init": "./wasm/init.js",
|
|
16
|
-
"./cloudflare": "./cloudflare/index.js",
|
|
17
|
-
"./aws-lambda": "./aws-lambda/index.js",
|
|
18
|
-
"./vercel": "./vercel/index.js"
|
|
16
|
+
"./cloudflare": "./platforms/cloudflare/index.js",
|
|
17
|
+
"./aws-lambda": "./platforms/aws-lambda/index.js",
|
|
18
|
+
"./vercel": "./platforms/vercel/index.js",
|
|
19
|
+
"./kv": "./runtime/kv.js",
|
|
20
|
+
"./db": "./runtime/db.js"
|
|
19
21
|
},
|
|
20
22
|
"homepage": "https://ziex.dev",
|
|
21
23
|
"repository": {
|
|
@@ -38,7 +40,7 @@
|
|
|
38
40
|
"license": "MIT",
|
|
39
41
|
"scripts": {},
|
|
40
42
|
"dependencies": {
|
|
41
|
-
"@ziex/cli": "0.1.0-dev.
|
|
43
|
+
"@ziex/cli": "0.1.0-dev.1458"
|
|
42
44
|
},
|
|
43
45
|
"module": "index.js"
|
|
44
46
|
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cloudflare D1 implements the generic {@link Database} binding.
|
|
3
|
+
* Prefer the generic names; D1* aliases are for Workers-typed `env.DB`.
|
|
4
|
+
*/
|
|
5
|
+
export { createDbImports } from "../../runtime/db";
|
|
6
|
+
export type { Database, Database as D1Database, PreparedStatement, PreparedStatement as D1PreparedStatement, ExecResult, ExecResult as D1ExecResult, DbValue, DbValue as D1Value, } from "../../runtime/db";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { WsState } from "
|
|
2
|
-
import type
|
|
3
|
-
import type {
|
|
1
|
+
import type { WsState } from "../../runtime";
|
|
2
|
+
import { type KVNamespace } from "../../runtime/kv";
|
|
3
|
+
import type { Database } from "../../runtime/db";
|
|
4
4
|
type ConnState = WsState & {
|
|
5
5
|
topics: Set<string>;
|
|
6
6
|
};
|
|
@@ -36,8 +36,8 @@ export declare function createWebSocketDO(module: WebAssembly.Module, options?:
|
|
|
36
36
|
* ```
|
|
37
37
|
*/
|
|
38
38
|
kv?: (env: any) => Record<string, KVNamespace>;
|
|
39
|
-
db?: (env: any) => Record<string,
|
|
40
|
-
imports?: (mem: () => WebAssembly.Memory) =>
|
|
39
|
+
db?: (env: any) => Record<string, Database>;
|
|
40
|
+
imports?: (mem: () => WebAssembly.Memory) => WebAssembly.Imports;
|
|
41
41
|
}): {
|
|
42
42
|
new (state: any, env: any): {
|
|
43
43
|
readonly doState: any;
|