devflare 1.0.0-next.14 → 1.0.0-next.16
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/LLM.md +9360 -1784
- package/README.md +391 -32
- package/bin/devflare.js +17 -7
- package/dist/account-0w8wdzjv.js +475 -0
- package/dist/account-eygq6qx7.js +475 -0
- package/dist/account-fw8nafav.js +475 -0
- package/dist/account-pzq69nys.js +475 -0
- package/dist/account-s66jb15j.js +475 -0
- package/dist/api-d6ekexs5.js +25 -0
- package/dist/bridge/index.d.ts +1 -1
- package/dist/bridge/index.d.ts.map +1 -1
- package/dist/bridge/miniflare.d.ts.map +1 -1
- package/dist/bridge/protocol.d.ts +1 -1
- package/dist/bridge/protocol.d.ts.map +1 -1
- package/dist/bridge/proxy.d.ts +0 -4
- package/dist/bridge/proxy.d.ts.map +1 -1
- package/dist/bridge/serialization.d.ts.map +1 -1
- package/dist/bridge/server.d.ts +1 -1
- package/dist/bridge/server.d.ts.map +1 -1
- package/dist/browser-shim/handler.d.ts +1 -1
- package/dist/browser-shim/handler.d.ts.map +1 -1
- package/dist/browser.d.ts +1651 -34
- package/dist/browser.d.ts.map +1 -1
- package/dist/build-1kmkwqgh.js +53 -0
- package/dist/build-506kjhcm.js +53 -0
- package/dist/build-66866ahs.js +53 -0
- package/dist/build-g1adm3ww.js +53 -0
- package/dist/build-p3r3117t.js +53 -0
- package/dist/bundler/do-bundler.d.ts.map +1 -1
- package/dist/bundler/rolldown-shared.d.ts +24 -0
- package/dist/bundler/rolldown-shared.d.ts.map +1 -0
- package/dist/bundler/worker-bundler.d.ts +0 -1
- package/dist/bundler/worker-bundler.d.ts.map +1 -1
- package/dist/cli/command-utils.d.ts +18 -0
- package/dist/cli/command-utils.d.ts.map +1 -0
- package/dist/cli/commands/account.d.ts +1 -1
- package/dist/cli/commands/account.d.ts.map +1 -1
- package/dist/cli/commands/build-artifacts.d.ts +27 -0
- package/dist/cli/commands/build-artifacts.d.ts.map +1 -0
- package/dist/cli/commands/build.d.ts.map +1 -1
- package/dist/cli/commands/config.d.ts +4 -0
- package/dist/cli/commands/config.d.ts.map +1 -0
- package/dist/cli/commands/deploy.d.ts.map +1 -1
- package/dist/cli/commands/dev.d.ts.map +1 -1
- package/dist/cli/commands/doctor.d.ts.map +1 -1
- package/dist/cli/commands/init.d.ts.map +1 -1
- package/dist/cli/commands/login.d.ts +4 -0
- package/dist/cli/commands/login.d.ts.map +1 -0
- package/dist/cli/commands/previews-support/cleanup.d.ts +9 -0
- package/dist/cli/commands/previews-support/cleanup.d.ts.map +1 -0
- package/dist/cli/commands/previews-support/family.d.ts +10 -0
- package/dist/cli/commands/previews-support/family.d.ts.map +1 -0
- package/dist/cli/commands/previews-support/render.d.ts +8 -0
- package/dist/cli/commands/previews-support/render.d.ts.map +1 -0
- package/dist/cli/commands/previews-support/theme.d.ts +10 -0
- package/dist/cli/commands/previews-support/theme.d.ts.map +1 -0
- package/dist/cli/commands/previews-support/types.d.ts +70 -0
- package/dist/cli/commands/previews-support/types.d.ts.map +1 -0
- package/dist/cli/commands/previews.d.ts +4 -0
- package/dist/cli/commands/previews.d.ts.map +1 -0
- package/dist/cli/commands/productions.d.ts +4 -0
- package/dist/cli/commands/productions.d.ts.map +1 -0
- package/dist/cli/commands/token.d.ts +4 -0
- package/dist/cli/commands/token.d.ts.map +1 -0
- package/dist/cli/commands/type-generation/discovery.d.ts +7 -0
- package/dist/cli/commands/type-generation/discovery.d.ts.map +1 -0
- package/dist/cli/commands/type-generation/generator.d.ts +44 -0
- package/dist/cli/commands/type-generation/generator.d.ts.map +1 -0
- package/dist/cli/commands/type-generation/models.d.ts +27 -0
- package/dist/cli/commands/type-generation/models.d.ts.map +1 -0
- package/dist/cli/commands/types.d.ts.map +1 -1
- package/dist/cli/commands/worker.d.ts +4 -0
- package/dist/cli/commands/worker.d.ts.map +1 -0
- package/dist/cli/config-path.d.ts +2 -1
- package/dist/cli/config-path.d.ts.map +1 -1
- package/dist/cli/deploy-strategy.d.ts +17 -0
- package/dist/cli/deploy-strategy.d.ts.map +1 -0
- package/dist/cli/deploy-target.d.ts +17 -0
- package/dist/cli/deploy-target.d.ts.map +1 -0
- package/dist/cli/generated-artifacts.d.ts +12 -0
- package/dist/cli/generated-artifacts.d.ts.map +1 -0
- package/dist/cli/help-pages/pages/account.d.ts +3 -0
- package/dist/cli/help-pages/pages/account.d.ts.map +1 -0
- package/dist/cli/help-pages/pages/core.d.ts +4 -0
- package/dist/cli/help-pages/pages/core.d.ts.map +1 -0
- package/dist/cli/help-pages/pages/index.d.ts +3 -0
- package/dist/cli/help-pages/pages/index.d.ts.map +1 -0
- package/dist/cli/help-pages/pages/misc.d.ts +3 -0
- package/dist/cli/help-pages/pages/misc.d.ts.map +1 -0
- package/dist/cli/help-pages/pages/previews.d.ts +3 -0
- package/dist/cli/help-pages/pages/previews.d.ts.map +1 -0
- package/dist/cli/help-pages/pages/productions.d.ts +3 -0
- package/dist/cli/help-pages/pages/productions.d.ts.map +1 -0
- package/dist/cli/help-pages/render.d.ts +12 -0
- package/dist/cli/help-pages/render.d.ts.map +1 -0
- package/dist/cli/help-pages/shared.d.ts +15 -0
- package/dist/cli/help-pages/shared.d.ts.map +1 -0
- package/dist/cli/help-pages/types.d.ts +23 -0
- package/dist/cli/help-pages/types.d.ts.map +1 -0
- package/dist/cli/help.d.ts +6 -0
- package/dist/cli/help.d.ts.map +1 -0
- package/dist/cli/index.d.ts +1 -0
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/preview-bindings.d.ts +42 -0
- package/dist/cli/preview-bindings.d.ts.map +1 -0
- package/dist/cli/preview.d.ts +11 -0
- package/dist/cli/preview.d.ts.map +1 -0
- package/dist/cli/ui.d.ts +37 -0
- package/dist/cli/ui.d.ts.map +1 -0
- package/dist/cli/workspace-build-guard.d.ts +14 -0
- package/dist/cli/workspace-build-guard.d.ts.map +1 -0
- package/dist/cloudflare/account-core.d.ts +6 -0
- package/dist/cloudflare/account-core.d.ts.map +1 -0
- package/dist/cloudflare/account-resources.d.ts +40 -0
- package/dist/cloudflare/account-resources.d.ts.map +1 -0
- package/dist/cloudflare/account-status.d.ts +11 -0
- package/dist/cloudflare/account-status.d.ts.map +1 -0
- package/dist/cloudflare/account-workers.d.ts +14 -0
- package/dist/cloudflare/account-workers.d.ts.map +1 -0
- package/dist/cloudflare/account.d.ts +7 -64
- package/dist/cloudflare/account.d.ts.map +1 -1
- package/dist/cloudflare/api.d.ts +4 -0
- package/dist/cloudflare/api.d.ts.map +1 -1
- package/dist/cloudflare/index.d.ts +57 -2
- package/dist/cloudflare/index.d.ts.map +1 -1
- package/dist/cloudflare/kv-namespace.d.ts +3 -0
- package/dist/cloudflare/kv-namespace.d.ts.map +1 -0
- package/dist/cloudflare/preferences.d.ts.map +1 -1
- package/dist/cloudflare/preview-registry-cache.d.ts +6 -0
- package/dist/cloudflare/preview-registry-cache.d.ts.map +1 -0
- package/dist/cloudflare/preview-registry-records.d.ts +61 -0
- package/dist/cloudflare/preview-registry-records.d.ts.map +1 -0
- package/dist/cloudflare/preview-registry-store.d.ts +14 -0
- package/dist/cloudflare/preview-registry-store.d.ts.map +1 -0
- package/dist/cloudflare/preview-registry-types.d.ts +103 -0
- package/dist/cloudflare/preview-registry-types.d.ts.map +1 -0
- package/dist/cloudflare/preview-registry.d.ts +42 -0
- package/dist/cloudflare/preview-registry.d.ts.map +1 -0
- package/dist/cloudflare/registry-schema.d.ts +253 -0
- package/dist/cloudflare/registry-schema.d.ts.map +1 -0
- package/dist/cloudflare/tokens.d.ts +18 -0
- package/dist/cloudflare/tokens.d.ts.map +1 -0
- package/dist/cloudflare/types.d.ts +122 -5
- package/dist/cloudflare/types.d.ts.map +1 -1
- package/dist/cloudflare/usage.d.ts.map +1 -1
- package/dist/config/compiler.d.ts +4 -0
- package/dist/config/compiler.d.ts.map +1 -1
- package/dist/config/framework-providers.d.ts +9 -0
- package/dist/config/framework-providers.d.ts.map +1 -0
- package/dist/config/index.d.ts +5 -3
- package/dist/config/index.d.ts.map +1 -1
- package/dist/config/loader.d.ts +1 -0
- package/dist/config/loader.d.ts.map +1 -1
- package/dist/config/preview-resources.d.ts +77 -0
- package/dist/config/preview-resources.d.ts.map +1 -0
- package/dist/config/preview.d.ts +31 -0
- package/dist/config/preview.d.ts.map +1 -0
- package/dist/config/ref.d.ts +0 -22
- package/dist/config/ref.d.ts.map +1 -1
- package/dist/config/resolve.d.ts +1 -0
- package/dist/config/resolve.d.ts.map +1 -1
- package/dist/config/resource-resolution.d.ts +60 -0
- package/dist/config/resource-resolution.d.ts.map +1 -0
- package/dist/config/schema-bindings.d.ts +693 -0
- package/dist/config/schema-bindings.d.ts.map +1 -0
- package/dist/config/schema-build.d.ts +67 -0
- package/dist/config/schema-build.d.ts.map +1 -0
- package/dist/config/schema-env.d.ts +1341 -0
- package/dist/config/schema-env.d.ts.map +1 -0
- package/dist/config/schema-normalization.d.ts +64 -0
- package/dist/config/schema-normalization.d.ts.map +1 -0
- package/dist/config/schema-runtime.d.ts +230 -0
- package/dist/config/schema-runtime.d.ts.map +1 -0
- package/dist/config/schema.d.ts +640 -3669
- package/dist/config/schema.d.ts.map +1 -1
- package/dist/config-entry.d.ts +5 -0
- package/dist/config-entry.d.ts.map +1 -0
- package/dist/config-fjwke42y.js +59 -0
- package/dist/config-hwdqjse7.js +59 -0
- package/dist/config-pxvewrhv.js +59 -0
- package/dist/config-q0g5qdga.js +59 -0
- package/dist/decorators/durable-object.d.ts.map +1 -1
- package/dist/deploy-7nmzc9r8.js +609 -0
- package/dist/deploy-csfhdr64.js +691 -0
- package/dist/deploy-ex4g5avz.js +621 -0
- package/dist/deploy-jnb0bhka.js +609 -0
- package/dist/deploy-tp0g6qdp.js +609 -0
- package/dist/deploy-ykpcjkc2.js +690 -0
- package/dist/{dev-c1xc1gq9.js → dev-2pd33m28.js} +392 -348
- package/dist/dev-7ef5e2j1.js +2409 -0
- package/dist/dev-8nssqatr.js +2409 -0
- package/dist/dev-grznx8fn.js +2409 -0
- package/dist/dev-server/d1-migrations.d.ts +14 -0
- package/dist/dev-server/d1-migrations.d.ts.map +1 -0
- package/dist/dev-server/gateway-script.d.ts +8 -0
- package/dist/dev-server/gateway-script.d.ts.map +1 -0
- package/dist/dev-server/runtime-stdio.d.ts.map +1 -1
- package/dist/dev-server/server.d.ts.map +1 -1
- package/dist/dev-server/vite-process.d.ts +14 -0
- package/dist/dev-server/vite-process.d.ts.map +1 -0
- package/dist/dev-server/vite-utils.d.ts +1 -1
- package/dist/dev-server/vite-utils.d.ts.map +1 -1
- package/dist/dev-server/worker-source-watcher.d.ts +11 -0
- package/dist/dev-server/worker-source-watcher.d.ts.map +1 -0
- package/dist/dev-server/worker-surface-paths.d.ts +6 -0
- package/dist/dev-server/worker-surface-paths.d.ts.map +1 -0
- package/dist/{doctor-z4ffybce.js → doctor-04ammrrh.js} +67 -31
- package/dist/doctor-fmjj65mc.js +245 -0
- package/dist/doctor-fzkznce1.js +245 -0
- package/dist/doctor-sa5xv1bz.js +245 -0
- package/dist/index-091sh1ma.js +1229 -0
- package/dist/index-0apbm26n.js +788 -0
- package/dist/index-0eqksag4.js +418 -0
- package/dist/{index-dr6sbp8d.js → index-0kfzdywd.js} +15 -2
- package/dist/index-0w826dsr.js +379 -0
- package/dist/{index-rfhx0yd5.js → index-11m5a8wd.js} +110 -32
- package/dist/{index-xxwbb2nt.js → index-1sp39f2f.js} +114 -58
- package/dist/index-2jnrqbny.js +1301 -0
- package/dist/index-2pb7b9mw.js +378 -0
- package/dist/{index-0kzg8wed.js → index-2x53aqjm.js} +1071 -890
- package/dist/index-3ke5d2vn.js +1229 -0
- package/dist/index-43dq8yx8.js +788 -0
- package/dist/index-4rrttqj5.js +378 -0
- package/dist/index-4v9bc2pc.js +1367 -0
- package/dist/index-61jsjnsv.js +280 -0
- package/dist/index-6jef5emv.js +176 -0
- package/dist/index-6psz1h4c.js +788 -0
- package/dist/index-72mve6vh.js +168 -0
- package/dist/{index-zbvmtcn2.js → index-74198nxd.js} +179 -77
- package/dist/index-7g8zyws4.js +192 -0
- package/dist/index-7kcxjhta.js +456 -0
- package/dist/index-7v583xan.js +418 -0
- package/dist/index-7x0ybbtx.js +133 -0
- package/dist/index-816krz9p.js +52 -0
- package/dist/index-82f1z98k.js +41 -0
- package/dist/index-8t5nb4qx.js +133 -0
- package/dist/index-9az6s7ad.js +52 -0
- package/dist/{index-59df49vn.js → index-9ba1etyz.js} +29 -51
- package/dist/{index-001mw014.js → index-9fbtk7gv.js} +134 -248
- package/dist/index-9n6djthj.js +490 -0
- package/dist/index-aabgympv.js +39 -0
- package/dist/index-b8m6883k.js +74 -0
- package/dist/{index-5yxg30va.js → index-cgbvmse6.js} +15 -6
- package/dist/index-d8etnfef.js +1229 -0
- package/dist/index-e9yw4d6y.js +133 -0
- package/dist/index-epw1jxz5.js +1204 -0
- package/dist/index-f85s8gj3.js +2649 -0
- package/dist/index-fe2ngvh7.js +1229 -0
- package/dist/index-fvsadj32.js +192 -0
- package/dist/index-gs4y9gdf.js +456 -0
- package/dist/{index-fef08w43.js → index-h18pxvzs.js} +7 -6
- package/dist/index-hfj1a2c4.js +2649 -0
- package/dist/{index-8gtqgb3q.js → index-hjy8ctpc.js} +14 -92
- package/dist/index-htzf0py1.js +1204 -0
- package/dist/index-j185x270.js +897 -0
- package/dist/index-jb75kwa4.js +519 -0
- package/dist/index-jwd8pcb2.js +897 -0
- package/dist/index-k29yjhv0.js +52 -0
- package/dist/index-k6vq6kkt.js +456 -0
- package/dist/{index-vky23txa.js → index-m3fmw6mx.js} +2 -2
- package/dist/index-maxpsfk8.js +402 -0
- package/dist/index-mbdmrner.js +402 -0
- package/dist/index-mea5bc45.js +418 -0
- package/dist/index-mqekt778.js +185 -0
- package/dist/index-na3mnm1k.js +74 -0
- package/dist/index-p03n4qet.js +1367 -0
- package/dist/index-p296ban8.js +191 -0
- package/dist/index-pnbs1b8k.js +280 -0
- package/dist/index-q4kaz181.js +1207 -0
- package/dist/index-ry131z23.js +378 -0
- package/dist/index-sgb7c8nm.js +402 -0
- package/dist/index-sqrksgb2.js +133 -0
- package/dist/index-stgn34cr.js +148 -0
- package/dist/{index-v8vvsn9x.js → index-t08te69w.js} +1 -18
- package/dist/index-thna1tkd.js +280 -0
- package/dist/index-v5nmqthy.js +74 -0
- package/dist/{index-n932ytmq.js → index-vt4yxkmf.js} +2 -2
- package/dist/index-wyq6c6yj.js +402 -0
- package/dist/index-wztc9stx.js +418 -0
- package/dist/index-x9cwdxw5.js +456 -0
- package/dist/index-xk9djfjp.js +519 -0
- package/dist/index-yc0gcchc.js +418 -0
- package/dist/index-yqbxjysa.js +897 -0
- package/dist/index-yzddwp02.js +788 -0
- package/dist/index-zfhq6s96.js +74 -0
- package/dist/index-zt22fe2j.js +54 -0
- package/dist/index-zyt5byt6.js +2649 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/{init-na2atvz2.js → init-r4hnxan3.js} +24 -17
- package/dist/login-2hnz4m4n.js +77 -0
- package/dist/login-5bsxxpvc.js +77 -0
- package/dist/login-6tzvczw2.js +77 -0
- package/dist/login-bhaw72zc.js +77 -0
- package/dist/login-x8tgckqm.js +77 -0
- package/dist/previews-3rn8mz2c.js +1168 -0
- package/dist/previews-d487qde5.js +1200 -0
- package/dist/previews-gm3z0syj.js +1168 -0
- package/dist/previews-j9ymq4ys.js +1169 -0
- package/dist/previews-q031mx34.js +1168 -0
- package/dist/productions-120xg0aq.js +505 -0
- package/dist/productions-5ev5qweg.js +505 -0
- package/dist/productions-me3tdvr9.js +505 -0
- package/dist/productions-p5rbgp2f.js +505 -0
- package/dist/productions-x9p0pym1.js +505 -0
- package/dist/runtime/context-events.d.ts +13 -0
- package/dist/runtime/context-events.d.ts.map +1 -0
- package/dist/runtime/context-types.d.ts +82 -0
- package/dist/runtime/context-types.d.ts.map +1 -0
- package/dist/runtime/context.d.ts +6 -267
- package/dist/runtime/context.d.ts.map +1 -1
- package/dist/runtime/exports.d.ts +3 -3
- package/dist/runtime/index.d.ts +1 -1
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/middleware.d.ts +8 -38
- package/dist/runtime/middleware.d.ts.map +1 -1
- package/dist/src/browser.js +23 -14
- package/dist/src/cli/index.js +3 -1
- package/dist/src/cloudflare/index.js +49 -2
- package/dist/src/config-entry.js +14 -0
- package/dist/src/index.js +33 -20
- package/dist/src/runtime/index.js +3 -9
- package/dist/src/sveltekit/index.js +10 -7
- package/dist/src/test/index.js +16 -18
- package/dist/src/vite/index.js +7 -4
- package/dist/sveltekit/platform.d.ts +1 -1
- package/dist/sveltekit/platform.d.ts.map +1 -1
- package/dist/test/cf.d.ts +10 -10
- package/dist/test/email.d.ts.map +1 -1
- package/dist/test/index.d.ts +1 -6
- package/dist/test/index.d.ts.map +1 -1
- package/dist/test/queue.d.ts.map +1 -1
- package/dist/test/remote-ai.d.ts.map +1 -1
- package/dist/test/remote-cloudflare.d.ts +13 -0
- package/dist/test/remote-cloudflare.d.ts.map +1 -0
- package/dist/test/remote-vectorize.d.ts.map +1 -1
- package/dist/test/resolve-service-bindings.d.ts.map +1 -1
- package/dist/test/scheduled.d.ts.map +1 -1
- package/dist/test/should-skip.d.ts +0 -18
- package/dist/test/should-skip.d.ts.map +1 -1
- package/dist/test/simple-context-durable-objects.d.ts +6 -0
- package/dist/test/simple-context-durable-objects.d.ts.map +1 -0
- package/dist/test/simple-context-gateway-script.d.ts +2 -0
- package/dist/test/simple-context-gateway-script.d.ts.map +1 -0
- package/dist/test/simple-context-paths.d.ts +40 -0
- package/dist/test/simple-context-paths.d.ts.map +1 -0
- package/dist/test/simple-context.d.ts +1 -23
- package/dist/test/simple-context.d.ts.map +1 -1
- package/dist/test/tail.d.ts.map +1 -1
- package/dist/test/worker.d.ts.map +1 -1
- package/dist/token-kedhcret.js +419 -0
- package/dist/token-m8jmnjwk.js +419 -0
- package/dist/{types-sffr9681.js → types-0sqwkp7x.js} +244 -139
- package/dist/types-1gwr2ex6.js +572 -0
- package/dist/types-6e5yx6km.js +572 -0
- package/dist/types-p0gckpn6.js +572 -0
- package/dist/utils/send-email.d.ts.map +1 -1
- package/dist/vite/config-file.d.ts.map +1 -1
- package/dist/vite/plugin.d.ts.map +1 -1
- package/dist/worker-0srh2jfr.js +513 -0
- package/dist/worker-4xrfd10a.js +513 -0
- package/dist/worker-entry/composed-worker.d.ts +0 -7
- package/dist/worker-entry/composed-worker.d.ts.map +1 -1
- package/dist/worker-entry/surface-paths.d.ts +15 -0
- package/dist/worker-entry/surface-paths.d.ts.map +1 -0
- package/dist/worker-qtam8grz.js +513 -0
- package/dist/worker-qzm0b7br.js +513 -0
- package/dist/worker-y9ha6g44.js +513 -0
- package/package.json +17 -10
- package/R2.md +0 -200
- package/dist/account-8psavtg6.js +0 -420
- package/dist/build-n639efmn.js +0 -101
- package/dist/deploy-zvnq6xh7.js +0 -117
- package/dist/index-2q3pmzrx.js +0 -90
- package/dist/index-f4q0jbnj.js +0 -195
- package/dist/index-n7rs26ft.js +0 -77
- package/dist/index-tfyxa77h.js +0 -850
- package/dist/index-wyf3s77s.js +0 -343
- package/dist/test/multi-worker-context.d.ts +0 -114
- package/dist/test/multi-worker-context.d.ts.map +0 -1
package/dist/index-wyf3s77s.js
DELETED
|
@@ -1,343 +0,0 @@
|
|
|
1
|
-
// src/config/schema.ts
|
|
2
|
-
import { z } from "zod";
|
|
3
|
-
var dateRegex = /^\d{4}-\d{2}-\d{2}$/;
|
|
4
|
-
var compatibilityDateSchema = z.string().regex(dateRegex, {
|
|
5
|
-
message: "Compatibility date must be in YYYY-MM-DD format"
|
|
6
|
-
});
|
|
7
|
-
var routesConfigSchema = z.object({
|
|
8
|
-
dir: z.string(),
|
|
9
|
-
prefix: z.string().optional()
|
|
10
|
-
});
|
|
11
|
-
var filesSchema = z.object({
|
|
12
|
-
fetch: z.union([z.string(), z.literal(false)]).optional(),
|
|
13
|
-
queue: z.union([z.string(), z.literal(false)]).optional(),
|
|
14
|
-
scheduled: z.union([z.string(), z.literal(false)]).optional(),
|
|
15
|
-
email: z.union([z.string(), z.literal(false)]).optional(),
|
|
16
|
-
durableObjects: z.union([z.string(), z.literal(false)]).optional(),
|
|
17
|
-
entrypoints: z.union([z.string(), z.literal(false)]).optional(),
|
|
18
|
-
workflows: z.union([z.string(), z.literal(false)]).optional(),
|
|
19
|
-
routes: z.union([routesConfigSchema, z.literal(false)]).optional(),
|
|
20
|
-
transport: z.union([z.string(), z.null()]).optional()
|
|
21
|
-
}).optional();
|
|
22
|
-
var durableObjectBindingSchema = z.custom((val) => {
|
|
23
|
-
if (typeof val === "string")
|
|
24
|
-
return true;
|
|
25
|
-
if (val && typeof val === "object" && "className" in val) {
|
|
26
|
-
const obj = val;
|
|
27
|
-
return typeof obj.className === "string";
|
|
28
|
-
}
|
|
29
|
-
return false;
|
|
30
|
-
}, {
|
|
31
|
-
message: "Expected string or { className: string, scriptName?: string }"
|
|
32
|
-
});
|
|
33
|
-
var queueConsumerSchema = z.object({
|
|
34
|
-
queue: z.string(),
|
|
35
|
-
maxBatchSize: z.number().optional(),
|
|
36
|
-
maxBatchTimeout: z.number().optional(),
|
|
37
|
-
maxRetries: z.number().optional(),
|
|
38
|
-
deadLetterQueue: z.string().optional(),
|
|
39
|
-
maxConcurrency: z.number().optional(),
|
|
40
|
-
retryDelay: z.number().optional()
|
|
41
|
-
});
|
|
42
|
-
var queuesConfigSchema = z.object({
|
|
43
|
-
producers: z.record(z.string(), z.string()).optional(),
|
|
44
|
-
consumers: z.array(queueConsumerSchema).optional()
|
|
45
|
-
});
|
|
46
|
-
var serviceBindingSchema = z.custom((val) => {
|
|
47
|
-
if (typeof val !== "object" && typeof val !== "function")
|
|
48
|
-
return false;
|
|
49
|
-
const obj = val;
|
|
50
|
-
const service = obj.service;
|
|
51
|
-
if (typeof service !== "string")
|
|
52
|
-
return false;
|
|
53
|
-
return true;
|
|
54
|
-
}, {
|
|
55
|
-
message: "Expected service binding object with { service: string } or ref().worker"
|
|
56
|
-
});
|
|
57
|
-
var aiBindingSchema = z.object({
|
|
58
|
-
binding: z.string()
|
|
59
|
-
});
|
|
60
|
-
var vectorizeBindingSchema = z.object({
|
|
61
|
-
indexName: z.string()
|
|
62
|
-
});
|
|
63
|
-
var hyperdriveBindingSchema = z.object({
|
|
64
|
-
id: z.string()
|
|
65
|
-
});
|
|
66
|
-
var browserBindingSchema = z.object({
|
|
67
|
-
binding: z.string()
|
|
68
|
-
});
|
|
69
|
-
var analyticsBindingSchema = z.object({
|
|
70
|
-
dataset: z.string()
|
|
71
|
-
});
|
|
72
|
-
var sendEmailBindingSchema = z.object({
|
|
73
|
-
destinationAddress: z.string().optional(),
|
|
74
|
-
allowedDestinationAddresses: z.array(z.string()).optional(),
|
|
75
|
-
allowedSenderAddresses: z.array(z.string()).optional()
|
|
76
|
-
}).refine((binding) => {
|
|
77
|
-
return !(binding.destinationAddress && binding.allowedDestinationAddresses);
|
|
78
|
-
}, {
|
|
79
|
-
message: "sendEmail bindings must use either destinationAddress or allowedDestinationAddresses, not both",
|
|
80
|
-
path: ["allowedDestinationAddresses"]
|
|
81
|
-
});
|
|
82
|
-
var bindingsSchema = z.object({
|
|
83
|
-
kv: z.record(z.string(), z.string()).optional(),
|
|
84
|
-
d1: z.record(z.string(), z.string()).optional(),
|
|
85
|
-
r2: z.record(z.string(), z.string()).optional(),
|
|
86
|
-
durableObjects: z.record(z.string(), durableObjectBindingSchema).optional(),
|
|
87
|
-
queues: queuesConfigSchema.optional(),
|
|
88
|
-
services: z.record(z.string(), serviceBindingSchema).optional(),
|
|
89
|
-
ai: aiBindingSchema.optional(),
|
|
90
|
-
vectorize: z.record(z.string(), vectorizeBindingSchema).optional(),
|
|
91
|
-
hyperdrive: z.record(z.string(), hyperdriveBindingSchema).optional(),
|
|
92
|
-
browser: browserBindingSchema.optional(),
|
|
93
|
-
analyticsEngine: z.record(z.string(), analyticsBindingSchema).optional(),
|
|
94
|
-
sendEmail: z.record(z.string(), sendEmailBindingSchema).optional()
|
|
95
|
-
}).optional();
|
|
96
|
-
var triggersSchema = z.object({
|
|
97
|
-
crons: z.array(z.string()).optional()
|
|
98
|
-
}).optional();
|
|
99
|
-
var secretConfigSchema = z.object({
|
|
100
|
-
required: z.boolean().optional().default(true)
|
|
101
|
-
});
|
|
102
|
-
var routeConfigSchema = z.object({
|
|
103
|
-
pattern: z.string(),
|
|
104
|
-
zone_name: z.string().optional(),
|
|
105
|
-
zone_id: z.string().optional(),
|
|
106
|
-
custom_domain: z.boolean().optional()
|
|
107
|
-
});
|
|
108
|
-
var wsRouteConfigSchema = z.object({
|
|
109
|
-
pattern: z.string(),
|
|
110
|
-
doNamespace: z.string(),
|
|
111
|
-
idParam: z.string().default("id"),
|
|
112
|
-
forwardPath: z.string().default("/websocket")
|
|
113
|
-
});
|
|
114
|
-
var assetsConfigSchema = z.object({
|
|
115
|
-
directory: z.string(),
|
|
116
|
-
binding: z.string().optional()
|
|
117
|
-
}).optional();
|
|
118
|
-
var observabilitySchema = z.object({
|
|
119
|
-
enabled: z.boolean().optional(),
|
|
120
|
-
head_sampling_rate: z.number().min(0).max(1).optional()
|
|
121
|
-
}).optional();
|
|
122
|
-
var limitsSchema = z.object({
|
|
123
|
-
cpu_ms: z.number().optional()
|
|
124
|
-
}).optional();
|
|
125
|
-
var rolldownOptionsSchema = z.custom((value) => {
|
|
126
|
-
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
127
|
-
}, {
|
|
128
|
-
message: "Expected Rolldown options object"
|
|
129
|
-
});
|
|
130
|
-
var rolldownConfigSchema = z.object({
|
|
131
|
-
target: z.string().optional(),
|
|
132
|
-
minify: z.boolean().optional(),
|
|
133
|
-
sourcemap: z.boolean().optional(),
|
|
134
|
-
options: rolldownOptionsSchema.optional()
|
|
135
|
-
}).optional();
|
|
136
|
-
var viteConfigSchema = z.object({
|
|
137
|
-
plugins: z.array(z.unknown()).optional()
|
|
138
|
-
}).catchall(z.unknown()).optional();
|
|
139
|
-
var buildConfigSchema = z.object({
|
|
140
|
-
target: z.string().optional(),
|
|
141
|
-
minify: z.boolean().optional(),
|
|
142
|
-
sourcemap: z.boolean().optional(),
|
|
143
|
-
rolldownOptions: rolldownOptionsSchema.optional()
|
|
144
|
-
}).optional();
|
|
145
|
-
function normalizeViteConfig(vite, plugins) {
|
|
146
|
-
const normalizedVite = {
|
|
147
|
-
...plugins !== undefined ? { plugins } : {},
|
|
148
|
-
...vite ?? {}
|
|
149
|
-
};
|
|
150
|
-
return Object.keys(normalizedVite).length > 0 ? normalizedVite : undefined;
|
|
151
|
-
}
|
|
152
|
-
function normalizeRolldownConfig(rolldown, build) {
|
|
153
|
-
const normalizedRolldown = {
|
|
154
|
-
...build?.target !== undefined ? { target: build.target } : {},
|
|
155
|
-
...build?.minify !== undefined ? { minify: build.minify } : {},
|
|
156
|
-
...build?.sourcemap !== undefined ? { sourcemap: build.sourcemap } : {},
|
|
157
|
-
...build?.rolldownOptions !== undefined ? { options: build.rolldownOptions } : {},
|
|
158
|
-
...rolldown ?? {}
|
|
159
|
-
};
|
|
160
|
-
return Object.keys(normalizedRolldown).length > 0 ? normalizedRolldown : undefined;
|
|
161
|
-
}
|
|
162
|
-
var migrationSchema = z.object({
|
|
163
|
-
tag: z.string(),
|
|
164
|
-
new_classes: z.array(z.string()).optional(),
|
|
165
|
-
renamed_classes: z.array(z.object({
|
|
166
|
-
from: z.string(),
|
|
167
|
-
to: z.string()
|
|
168
|
-
})).optional(),
|
|
169
|
-
deleted_classes: z.array(z.string()).optional(),
|
|
170
|
-
new_sqlite_classes: z.array(z.string()).optional()
|
|
171
|
-
});
|
|
172
|
-
var wranglerConfigSchema = z.object({
|
|
173
|
-
passthrough: z.record(z.string(), z.unknown()).optional()
|
|
174
|
-
}).optional();
|
|
175
|
-
var envConfigSchema = z.object({
|
|
176
|
-
name: z.string().optional(),
|
|
177
|
-
compatibilityDate: compatibilityDateSchema.optional(),
|
|
178
|
-
compatibilityFlags: z.array(z.string()).optional(),
|
|
179
|
-
files: filesSchema,
|
|
180
|
-
bindings: bindingsSchema,
|
|
181
|
-
triggers: triggersSchema,
|
|
182
|
-
vars: z.record(z.string(), z.string()).optional(),
|
|
183
|
-
secrets: z.record(z.string(), secretConfigSchema).optional(),
|
|
184
|
-
routes: z.array(routeConfigSchema).optional(),
|
|
185
|
-
assets: assetsConfigSchema,
|
|
186
|
-
limits: limitsSchema,
|
|
187
|
-
observability: observabilitySchema,
|
|
188
|
-
migrations: z.array(migrationSchema).optional(),
|
|
189
|
-
rolldown: rolldownConfigSchema,
|
|
190
|
-
vite: viteConfigSchema,
|
|
191
|
-
wrangler: wranglerConfigSchema
|
|
192
|
-
}).partial();
|
|
193
|
-
var envConfigSchemaInner = envConfigSchema.extend({
|
|
194
|
-
build: buildConfigSchema,
|
|
195
|
-
plugins: z.array(z.unknown()).optional()
|
|
196
|
-
}).transform((config) => {
|
|
197
|
-
const normalizedVite = normalizeViteConfig(config.vite, config.plugins);
|
|
198
|
-
const normalizedRolldown = normalizeRolldownConfig(config.rolldown, config.build);
|
|
199
|
-
const {
|
|
200
|
-
build: _legacyBuild,
|
|
201
|
-
plugins: _legacyPlugins,
|
|
202
|
-
vite: _vite,
|
|
203
|
-
rolldown: _rolldown,
|
|
204
|
-
...rest
|
|
205
|
-
} = config;
|
|
206
|
-
return {
|
|
207
|
-
...rest,
|
|
208
|
-
...normalizedVite ? { vite: normalizedVite } : {},
|
|
209
|
-
...normalizedRolldown ? { rolldown: normalizedRolldown } : {}
|
|
210
|
-
};
|
|
211
|
-
});
|
|
212
|
-
function getCurrentDate() {
|
|
213
|
-
const now = new Date;
|
|
214
|
-
return now.toISOString().split("T")[0];
|
|
215
|
-
}
|
|
216
|
-
var FORCED_COMPATIBILITY_FLAGS = ["nodejs_compat", "nodejs_als"];
|
|
217
|
-
var canonicalConfigSchema = z.object({
|
|
218
|
-
name: z.string({
|
|
219
|
-
required_error: "Worker name is required"
|
|
220
|
-
}),
|
|
221
|
-
accountId: z.string().optional(),
|
|
222
|
-
compatibilityDate: compatibilityDateSchema.optional().default(getCurrentDate),
|
|
223
|
-
compatibilityFlags: z.array(z.string()).optional().transform((flags = []) => {
|
|
224
|
-
const merged = new Set([...FORCED_COMPATIBILITY_FLAGS, ...flags]);
|
|
225
|
-
return [...merged];
|
|
226
|
-
}),
|
|
227
|
-
files: filesSchema,
|
|
228
|
-
bindings: bindingsSchema,
|
|
229
|
-
triggers: triggersSchema,
|
|
230
|
-
vars: z.record(z.string(), z.string()).optional(),
|
|
231
|
-
secrets: z.record(z.string(), secretConfigSchema).optional(),
|
|
232
|
-
routes: z.array(routeConfigSchema).optional(),
|
|
233
|
-
wsRoutes: z.array(wsRouteConfigSchema).optional(),
|
|
234
|
-
assets: assetsConfigSchema,
|
|
235
|
-
limits: limitsSchema,
|
|
236
|
-
observability: observabilitySchema,
|
|
237
|
-
migrations: z.array(migrationSchema).optional(),
|
|
238
|
-
rolldown: rolldownConfigSchema,
|
|
239
|
-
vite: viteConfigSchema,
|
|
240
|
-
env: z.record(z.string(), envConfigSchemaInner).optional(),
|
|
241
|
-
wrangler: wranglerConfigSchema
|
|
242
|
-
});
|
|
243
|
-
var configSchema = canonicalConfigSchema.extend({
|
|
244
|
-
build: buildConfigSchema,
|
|
245
|
-
plugins: z.array(z.unknown()).optional()
|
|
246
|
-
}).transform((config) => {
|
|
247
|
-
const normalizedVite = normalizeViteConfig(config.vite, config.plugins);
|
|
248
|
-
const normalizedRolldown = normalizeRolldownConfig(config.rolldown, config.build);
|
|
249
|
-
const {
|
|
250
|
-
build: _legacyBuild,
|
|
251
|
-
plugins: _legacyPlugins,
|
|
252
|
-
vite: _vite,
|
|
253
|
-
rolldown: _rolldown,
|
|
254
|
-
...rest
|
|
255
|
-
} = config;
|
|
256
|
-
return {
|
|
257
|
-
...rest,
|
|
258
|
-
...normalizedVite ? { vite: normalizedVite } : {},
|
|
259
|
-
...normalizedRolldown ? { rolldown: normalizedRolldown } : {}
|
|
260
|
-
};
|
|
261
|
-
});
|
|
262
|
-
function normalizeDOBinding(config) {
|
|
263
|
-
if (typeof config === "string") {
|
|
264
|
-
return { className: config };
|
|
265
|
-
}
|
|
266
|
-
return {
|
|
267
|
-
className: config.className,
|
|
268
|
-
scriptName: config.scriptName,
|
|
269
|
-
__ref: config.__ref
|
|
270
|
-
};
|
|
271
|
-
}
|
|
272
|
-
|
|
273
|
-
// src/config/loader.ts
|
|
274
|
-
import { loadConfig as c12LoadConfig } from "c12";
|
|
275
|
-
import { existsSync } from "node:fs";
|
|
276
|
-
import { join } from "pathe";
|
|
277
|
-
var CONFIG_FILES = [
|
|
278
|
-
"devflare.config.ts",
|
|
279
|
-
"devflare.config.mts",
|
|
280
|
-
"devflare.config.js",
|
|
281
|
-
"devflare.config.mjs"
|
|
282
|
-
];
|
|
283
|
-
async function resolveConfigPath(cwd) {
|
|
284
|
-
for (const file of CONFIG_FILES) {
|
|
285
|
-
const path = join(cwd, file);
|
|
286
|
-
if (existsSync(path)) {
|
|
287
|
-
return path;
|
|
288
|
-
}
|
|
289
|
-
}
|
|
290
|
-
return;
|
|
291
|
-
}
|
|
292
|
-
async function loadConfig(options = {}) {
|
|
293
|
-
const cwd = options.cwd ?? process.cwd();
|
|
294
|
-
const configFile = options.configFile ?? "devflare.config";
|
|
295
|
-
const { config, configFile: loadedFile } = await c12LoadConfig({
|
|
296
|
-
name: "devflare",
|
|
297
|
-
cwd,
|
|
298
|
-
configFile,
|
|
299
|
-
defaultConfig: undefined,
|
|
300
|
-
rcFile: false,
|
|
301
|
-
globalRc: false,
|
|
302
|
-
dotenv: false
|
|
303
|
-
});
|
|
304
|
-
if (!config || !loadedFile) {
|
|
305
|
-
throw new ConfigNotFoundError(cwd, configFile);
|
|
306
|
-
}
|
|
307
|
-
const result = configSchema.safeParse(config);
|
|
308
|
-
if (!result.success) {
|
|
309
|
-
throw new ConfigValidationError(result.error.issues, loadedFile);
|
|
310
|
-
}
|
|
311
|
-
return result.data;
|
|
312
|
-
}
|
|
313
|
-
|
|
314
|
-
class ConfigNotFoundError extends Error {
|
|
315
|
-
cwd;
|
|
316
|
-
configFile;
|
|
317
|
-
code = "CONFIG_NOT_FOUND";
|
|
318
|
-
constructor(cwd, configFile) {
|
|
319
|
-
super(`Config file not found in ${cwd}.
|
|
320
|
-
` + `Expected one of: ${CONFIG_FILES.join(", ")}
|
|
321
|
-
` + `Run 'devflare init' to create a new config.`);
|
|
322
|
-
this.cwd = cwd;
|
|
323
|
-
this.configFile = configFile;
|
|
324
|
-
this.name = "ConfigNotFoundError";
|
|
325
|
-
}
|
|
326
|
-
}
|
|
327
|
-
|
|
328
|
-
class ConfigValidationError extends Error {
|
|
329
|
-
issues;
|
|
330
|
-
configFile;
|
|
331
|
-
code = "CONFIG_VALIDATION_ERROR";
|
|
332
|
-
constructor(issues, configFile) {
|
|
333
|
-
const issueMessages = issues.map((i) => ` - ${i.path.join(".")}: ${i.message}`).join(`
|
|
334
|
-
`);
|
|
335
|
-
super(`Invalid config in ${configFile}:
|
|
336
|
-
${issueMessages}`);
|
|
337
|
-
this.issues = issues;
|
|
338
|
-
this.configFile = configFile;
|
|
339
|
-
this.name = "ConfigValidationError";
|
|
340
|
-
}
|
|
341
|
-
}
|
|
342
|
-
|
|
343
|
-
export { configSchema, normalizeDOBinding, resolveConfigPath, loadConfig, ConfigNotFoundError, ConfigValidationError };
|
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
import type { Miniflare } from 'miniflare';
|
|
2
|
-
/**
|
|
3
|
-
* Configuration for a worker in a multi-worker test
|
|
4
|
-
*/
|
|
5
|
-
export interface WorkerConfig {
|
|
6
|
-
/** Worker name (used for service binding references) */
|
|
7
|
-
name: string;
|
|
8
|
-
/** Worker script code as string */
|
|
9
|
-
script: string;
|
|
10
|
-
/** Whether the script uses ES modules (default: true) */
|
|
11
|
-
modules?: boolean;
|
|
12
|
-
/** Compatibility date (default: '2025-01-01') */
|
|
13
|
-
compatibilityDate?: string;
|
|
14
|
-
/**
|
|
15
|
-
* Service bindings to other workers
|
|
16
|
-
* Key: binding name, Value: worker name or { name, entrypoint }
|
|
17
|
-
*/
|
|
18
|
-
serviceBindings?: Record<string, string | {
|
|
19
|
-
name: string;
|
|
20
|
-
entrypoint: string;
|
|
21
|
-
}>;
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* Options for creating a multi-worker test context
|
|
25
|
-
*/
|
|
26
|
-
export interface MultiWorkerContextOptions {
|
|
27
|
-
/** Array of worker configurations */
|
|
28
|
-
workers: WorkerConfig[];
|
|
29
|
-
/**
|
|
30
|
-
* Name of the primary worker (receives HTTP requests)
|
|
31
|
-
* Defaults to first worker in the array
|
|
32
|
-
*/
|
|
33
|
-
primary?: string;
|
|
34
|
-
}
|
|
35
|
-
/**
|
|
36
|
-
* Result of creating a multi-worker test context
|
|
37
|
-
*/
|
|
38
|
-
export interface MultiWorkerContext<TEnv = Record<string, unknown>> {
|
|
39
|
-
/** Miniflare instance */
|
|
40
|
-
mf: Miniflare;
|
|
41
|
-
/** Environment bindings from the primary worker */
|
|
42
|
-
env: TEnv;
|
|
43
|
-
/** Dispatch a fetch request to the primary worker */
|
|
44
|
-
fetch: (input: string | URL | Request, init?: RequestInit) => Promise<Response>;
|
|
45
|
-
/** Dispose of the context (cleanup) */
|
|
46
|
-
dispose: () => Promise<void>;
|
|
47
|
-
}
|
|
48
|
-
/**
|
|
49
|
-
* @deprecated Use `createTestContext()` instead. It now automatically detects service bindings
|
|
50
|
-
* from `ref()` metadata in your devflare.config.ts and sets up multi-worker Miniflare.
|
|
51
|
-
*
|
|
52
|
-
* Create a multi-worker test context for testing RPC between workers.
|
|
53
|
-
*
|
|
54
|
-
* @example
|
|
55
|
-
* ```ts
|
|
56
|
-
* const gatewayScript = `
|
|
57
|
-
* export default {
|
|
58
|
-
* async fetch(request, env) {
|
|
59
|
-
* const sum = await env.MATH.add(1, 2)
|
|
60
|
-
* return Response.json({ sum })
|
|
61
|
-
* }
|
|
62
|
-
* }
|
|
63
|
-
* `
|
|
64
|
-
*
|
|
65
|
-
* const mathScript = `
|
|
66
|
-
* import { WorkerEntrypoint } from 'cloudflare:workers'
|
|
67
|
-
* export class MathService extends WorkerEntrypoint {
|
|
68
|
-
* add(a, b) { return a + b }
|
|
69
|
-
* }
|
|
70
|
-
* `
|
|
71
|
-
*
|
|
72
|
-
* const ctx = await createMultiWorkerContext({
|
|
73
|
-
* workers: [
|
|
74
|
-
* { name: 'gateway', script: gatewayScript, serviceBindings: { MATH: { name: 'math', entrypoint: 'MathService' } } },
|
|
75
|
-
* { name: 'math', script: mathScript }
|
|
76
|
-
* ],
|
|
77
|
-
* primary: 'gateway'
|
|
78
|
-
* })
|
|
79
|
-
*
|
|
80
|
-
* // Direct RPC test
|
|
81
|
-
* const sum = await ctx.env.MATH.add(1, 2)
|
|
82
|
-
* expect(sum).toBe(3)
|
|
83
|
-
*
|
|
84
|
-
* // HTTP test (gateway using RPC internally)
|
|
85
|
-
* const response = await ctx.fetch('http://localhost/')
|
|
86
|
-
* const data = await response.json()
|
|
87
|
-
* expect(data.sum).toBe(3)
|
|
88
|
-
*
|
|
89
|
-
* await ctx.dispose()
|
|
90
|
-
* ```
|
|
91
|
-
*/
|
|
92
|
-
export declare function createMultiWorkerContext<TEnv = Record<string, unknown>>(options: MultiWorkerContextOptions): Promise<MultiWorkerContext<TEnv>>;
|
|
93
|
-
/**
|
|
94
|
-
* @deprecated Use `worker.ts` files with exported functions instead. devflare automatically
|
|
95
|
-
* transforms these into WorkerEntrypoint classes during bundling.
|
|
96
|
-
*
|
|
97
|
-
* Helper to create a WorkerEntrypoint class script from exported functions.
|
|
98
|
-
* Use this when you want to test against the transformed version of a worker.ts file.
|
|
99
|
-
*
|
|
100
|
-
* @example
|
|
101
|
-
* ```ts
|
|
102
|
-
* const script = createEntrypointScript('MathService', {
|
|
103
|
-
* add: '(a, b) { return a + b }',
|
|
104
|
-
* multiply: '(a, b) { return a * b }'
|
|
105
|
-
* })
|
|
106
|
-
* // Result: import { WorkerEntrypoint } from 'cloudflare:workers'
|
|
107
|
-
* // export class MathService extends WorkerEntrypoint {
|
|
108
|
-
* // add(a, b) { return a + b }
|
|
109
|
-
* // multiply(a, b) { return a * b }
|
|
110
|
-
* // }
|
|
111
|
-
* ```
|
|
112
|
-
*/
|
|
113
|
-
export declare function createEntrypointScript(className: string, methods: Record<string, string>): string;
|
|
114
|
-
//# sourceMappingURL=multi-worker-context.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"multi-worker-context.d.ts","sourceRoot":"","sources":["../../src/test/multi-worker-context.ts"],"names":[],"mappings":"AAqBA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,WAAW,CAAA;AAM1C;;GAEG;AACH,MAAM,WAAW,YAAY;IAC5B,wDAAwD;IACxD,IAAI,EAAE,MAAM,CAAA;IAEZ,mCAAmC;IACnC,MAAM,EAAE,MAAM,CAAA;IAEd,yDAAyD;IACzD,OAAO,CAAC,EAAE,OAAO,CAAA;IAEjB,iDAAiD;IACjD,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAE1B;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CAC/E;AAED;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACzC,qCAAqC;IACrC,OAAO,EAAE,YAAY,EAAE,CAAA;IAEvB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;CAChB;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB,CAAC,IAAI,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IACjE,yBAAyB;IACzB,EAAE,EAAE,SAAS,CAAA;IAEb,mDAAmD;IACnD,GAAG,EAAE,IAAI,CAAA;IAET,qDAAqD;IACrD,KAAK,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,GAAG,GAAG,OAAO,EAAE,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAA;IAE/E,uCAAuC;IACvC,OAAO,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAA;CAC5B;AAMD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AACH,wBAAsB,wBAAwB,CAAC,IAAI,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC5E,OAAO,EAAE,yBAAyB,GAChC,OAAO,CAAC,kBAAkB,CAAC,IAAI,CAAC,CAAC,CAiEnC;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,sBAAsB,CACrC,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAC7B,MAAM,CAWR"}
|