void 1.12.1 → 1.13.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/README.md +1 -0
- package/dist/{account-cmd-BU1Fy_Bf.mjs → account-cmd-4fQiXYX7.mjs} +6 -6
- package/dist/{application-analysis-DVeN8yoi.mjs → application-analysis-BjEwHTV2.mjs} +19 -13
- package/dist/{application-routing-KKw4Y84h.mjs → application-routing-COCfD2yc.mjs} +1 -1
- package/dist/args-DrnTI35r.mjs +88 -0
- package/dist/args-MnQnqypt.mjs +1 -0
- package/dist/{auth-CqwJwItO.mjs → auth-CeBmolb-.mjs} +3 -3
- package/dist/{auth-A7cZ8aXA.mjs → auth-CvaDxOMi.mjs} +1 -1
- package/dist/{auth-link-Duu2NvN5.mjs → auth-link-I4omV0pL.mjs} +6 -6
- package/dist/{auth-router-vgtOdb9j.mjs → auth-router-CXq4q7bb.mjs} +6 -5
- package/dist/{better-auth-shared-BS3pDQbT.d.mts → better-auth-shared-CrIkcN8I.d.mts} +2 -1
- package/dist/bindings-C7zOgxT3.d.mts +28 -0
- package/dist/browser-run-BKgZVwLk.mjs +124 -0
- package/dist/{build-cmd-B7OJ0U5R.mjs → build-cmd-Biz6u4rn.mjs} +6 -6
- package/dist/{cache-wSpi3aeM.mjs → cache-WkLMUrjQ.mjs} +6 -6
- package/dist/{cancel-deploy-DMWzkAlb.mjs → cancel-deploy-BRsrmyTk.mjs} +6 -5
- package/dist/{cf-access-DHklo7Rg.mjs → cf-access-B21j-nd6.mjs} +1 -1
- package/dist/{cf-build-output-Cso7Vh-t.mjs → cf-build-output-G-7Tdd8b.mjs} +6 -5
- package/dist/cf-build-output-Qc43LWzE.mjs +1 -0
- package/dist/{cf-command-values-5BPBRc9Z.mjs → cf-command-values-cUnJwCyG.mjs} +24 -1
- package/dist/{cf-config-migrate-D271BTiw.mjs → cf-config-migrate-CsbQGzMf.mjs} +200 -94
- package/dist/cf-user-agent-HHTRzfud.mjs +15 -0
- package/dist/cf-version-api-BWHMVtzw.mjs +1 -0
- package/dist/cf-version-api-XEEK2B9A.mjs +856 -0
- package/dist/cf-worker-settings-DJKdy97k.mjs +127 -0
- package/dist/cli/cli.mjs +1 -1
- package/dist/cli/cloudflare-operation-process.mjs +111 -47
- package/dist/cli/env-schema-probe.mjs +3 -3
- package/dist/cli/json-command-process.d.mts +6 -0
- package/dist/cli/json-command-process.mjs +91 -0
- package/dist/{cli-main-BrChcpE3.mjs → cli-main-CJTGhcYN.mjs} +84 -113
- package/dist/{client-eLZwqkPH.mjs → client-0um7Lzze.mjs} +1 -1
- package/dist/{client-DE2m2ldh.mjs → client-BEHI4UWn.mjs} +14 -8
- package/dist/{cloudflare-auth-eWfhdZCk.mjs → cloudflare-auth-iOgRurWm.mjs} +1 -1
- package/dist/{cloudflare-cmd-SsFlJe2B.mjs → cloudflare-cmd-DsSlXbNy.mjs} +5 -5
- package/dist/{cloudflare-config-D9UFH_A5.mjs → cloudflare-config-KPHKf57C.mjs} +2 -2
- package/dist/{cloudflare-connect-BgpHcSg3.mjs → cloudflare-connect-bEtneBjT.mjs} +5 -4
- package/dist/{cloudflare-operations-ByjFGats.mjs → cloudflare-operations-BmICrRnm.mjs} +1 -1
- package/dist/{cloudflare-operations-BIRQkYwL.mjs → cloudflare-operations-D-9psgPQ.mjs} +19 -11
- package/dist/cloudflare-preview-8eLSQPdO.mjs +1 -0
- package/dist/cloudflare-preview-BaeU-m74.mjs +112 -0
- package/dist/{cloudflare-process-60r4Z2Zf.mjs → cloudflare-process-DFNpqV_m.mjs} +57 -29
- package/dist/cloudflare-user-output-DFbD0l4l.mjs +36 -0
- package/dist/collect-Aam0GwAU.mjs +1 -0
- package/dist/{collect-rNLybAnF.mjs → collect-KC4cizWM.mjs} +6 -1
- package/dist/{config-DA6ZbLXO.d.mts → config-BdmM5ZzP.d.mts} +12 -2
- package/dist/{config-BFX5ZB1J.mjs → config-CUYGZqdN.mjs} +2 -2
- package/dist/{config-BSoW3QCB.mjs → config-C_UjzkVS.mjs} +3 -3
- package/dist/{config-DtjrUtPo.mjs → config-Ge-MytMU.mjs} +1 -1
- package/dist/{config-Dv5jri1-.mjs → config-KZAiI3gG.mjs} +32 -6
- package/dist/config-entry.d.mts +1 -1
- package/dist/config-write-dKLINlm2.mjs +80 -0
- package/dist/{connect-D0V0o40j.mjs → connect-Bqq3b9sX.mjs} +10 -9
- package/dist/{create-project-CbuDH5Hv.mjs → create-project-MXoP_rte.mjs} +1 -1
- package/dist/{create-project-8FdN6D2i.mjs → create-project-T-9AIQDe.mjs} +7 -6
- package/dist/{db-BNPIjLkK.mjs → db-B3eoVDNA.mjs} +50 -47
- package/dist/{db-args-CiQVg8SJ.mjs → db-args-BcvTZ8KE.mjs} +1 -1
- package/dist/db-args-Cx1y4vZn.mjs +1 -0
- package/dist/{db-types-B4Cf9dzR.mjs → db-types-BpgXVtQZ.mjs} +1 -1
- package/dist/{delete-WtLEfap2.mjs → delete-Cf6SroAw.mjs} +7 -6
- package/dist/deploy-DZ9j7MC4.mjs +2 -0
- package/dist/{deploy-BgSbagIP.mjs → deploy-UojYUEWr.mjs} +803 -1415
- package/dist/{deploy-managed-static-BWBsxOww.mjs → deploy-managed-static-DV_OmTWf.mjs} +54 -393
- package/dist/{deploy-security-notice-IRGy6Edf.mjs → deploy-security-notice-3jX71IeP.mjs} +6 -4
- package/dist/deploy-summary-Dkl0zvQy.mjs +377 -0
- package/dist/{deploy-transport-BKP_oV9q.mjs → deploy-transport-4ISWxx8n.mjs} +4 -3
- package/dist/deploy.mjs +14 -10
- package/dist/discover-BZWVWeQs.mjs +1 -0
- package/dist/{discover-IcspacCg.mjs → discover-BeFs7OPS.mjs} +1 -1
- package/dist/{dispatch-DIhDA3NI.mjs → dispatch-BUKbPdqb.mjs} +7 -7
- package/dist/{dist-Cr_xGE_K.mjs → dist-BngS28id.mjs} +6 -6
- package/dist/{dist-C47zy_kJ.mjs → dist-x99fIj4n.mjs} +1 -1
- package/dist/{domain-mweyYXSw.mjs → domain-BK6NWkWK.mjs} +7 -7
- package/dist/{drizzle-BJDMPrj7.mjs → drizzle-CnSbVeiZ.mjs} +12 -13
- package/dist/{drizzle-CQ5jWuDL.mjs → drizzle-CrkwVwK8.mjs} +1 -1
- package/dist/{email-DcQNP40O.mjs → email-BBSDV0J5.mjs} +13 -12
- package/dist/{email-cloudflare-DeYH3Ke7.mjs → email-cloudflare-C-guKEbz.mjs} +10 -8
- package/dist/{env-DaAoYR2-.mjs → env-BVnKiGYJ.mjs} +8 -8
- package/dist/{env-EjHqc7m9.mjs → env-CU2tMDdO.mjs} +6 -1
- package/dist/{env-types-D2hBodXP.mjs → env-types-B33fEHRH.mjs} +1 -1
- package/dist/{env-validation-j9pjCDfA.mjs → env-validation-BnAsx6gz.mjs} +1 -1
- package/dist/{env-validation-D-v5_CWL.mjs → env-validation-SXsjd6-Z.mjs} +4 -4
- package/dist/{fetch-CiEsvjpP.mjs → fetch-DL7OCgwB.mjs} +1 -1
- package/dist/{fetch-stream-BIG5lHW6.mjs → fetch-stream-DEilLTCc.mjs} +2 -2
- package/dist/{gen-aOtHhZLD.mjs → gen-BxuIN1bz.mjs} +10 -9
- package/dist/gen-DaayFP9v.mjs +1 -0
- package/dist/{generate-Dq2Bgw75.mjs → generate-Ck-L3e0e.mjs} +1 -1
- package/dist/{generate-C3ZAqCy-.mjs → generate-t1dDUYZZ.mjs} +1 -1
- package/dist/{github-cmd-BR19Ffdz.mjs → github-cmd-B7U9Hjmi.mjs} +7 -6
- package/dist/{handler-DCrDLzw2.mjs → handler-2wAywJgj.mjs} +11 -9
- package/dist/{headers-DqBsjDxg.mjs → headers-DPI4MDGC.mjs} +1 -1
- package/dist/{help-DvClCzqL.mjs → help-Bgiu5PMX.mjs} +36 -4
- package/dist/help-DWGHmt_n.mjs +1 -0
- package/dist/html-5sfGLjiI.d.mts +3 -0
- package/dist/html-DPSOBDCh.mjs +1 -0
- package/dist/{index-Dn2mkPr2.d.mts → index-CqF8_p9C.d.mts} +5 -105
- package/dist/index-Cvqotnhc.d.mts +91 -0
- package/dist/{index-BQ5qYiAw.d.mts → index-DAinHkj8.d.mts} +1 -1
- package/dist/{index-8cAgNdb6.d.mts → index-lnEWwVAS.d.mts} +1 -1
- package/dist/index.d.mts +3 -2
- package/dist/index.mjs +536 -170
- package/dist/{info-P6MBiVJi.mjs → info-7COlpAfY.mjs} +32 -20
- package/dist/{init-C8YpkGIP.mjs → init-DftAx3L4.mjs} +237 -88
- package/dist/input-jcps6lAn.mjs +64 -0
- package/dist/interactive-prompts-EK0dilFu.mjs +43 -0
- package/dist/{limits-BCoQLpn3.mjs → limits-3I3VdX2E.mjs} +4 -1
- package/dist/{link-Dyz9IGcM.mjs → link-C3WMNFTG.mjs} +7 -7
- package/dist/{list-VGYBMjmx.mjs → list-K4EGVUZN.mjs} +9 -9
- package/dist/{load-user-env-B8qC0Q2Y.mjs → load-user-env-uMmQJ-Th.mjs} +1 -1
- package/dist/{local-d1-CYOYkVwO.mjs → local-d1-BtLCVC1p.mjs} +2 -2
- package/dist/login-BJwPhV_S.mjs +1 -0
- package/dist/{login-CWFr-G2I.mjs → login-DaugBfBG.mjs} +6 -5
- package/dist/{logs-kS1wuR4b.mjs → logs-BR2szdN5.mjs} +6 -6
- package/dist/migrate-BHD46A31.mjs +1 -0
- package/dist/{migrate-BNZL1hee.mjs → migrate-Dtlg8fC6.mjs} +7 -7
- package/dist/nitro.mjs +3 -3
- package/dist/{node-DVJWfV6s.mjs → node-BbKlLpHa.mjs} +5 -5
- package/dist/{operator-ai-logging-DD0n6zc2.mjs → operator-ai-logging-4Nvs6Ut3.mjs} +5 -5
- package/dist/{operator-args-nvetCWuz.mjs → operator-args-DWvqq3Ws.mjs} +31 -15
- package/dist/{operator-auth-DMvn-y9X.mjs → operator-auth-DtRMGXYY.mjs} +2 -2
- package/dist/{operator-client-dFNnXfyB.mjs → operator-client-BG0VIMMM.mjs} +2 -2
- package/dist/operator-cmd-CR3Q9k4c.mjs +1 -0
- package/dist/{operator-cmd-a7yOf2tH.mjs → operator-cmd-D4YcMKO-.mjs} +9 -9
- package/dist/{operator-security-D5MToU0p.mjs → operator-security-nVLo8vDt.mjs} +11 -5
- package/dist/{output-BZLnu0z8.mjs → output-DhJgS6Ve.mjs} +1 -1
- package/dist/output-OYwcEwok.mjs +1 -0
- package/dist/pages/client.d.mts +34 -20
- package/dist/pages/client.mjs +172 -74
- package/dist/pages/index.d.mts +11 -4
- package/dist/pages/index.mjs +5 -5
- package/dist/pages/islands-plugin.d.mts +2 -2
- package/dist/pages/islands-plugin.mjs +5 -3
- package/dist/pages/protocol.d.mts +3 -3
- package/dist/pages/protocol.mjs +3 -3
- package/dist/pages/serialize.d.mts +2 -2
- package/dist/pages/serialize.mjs +1 -1
- package/dist/parse-filename-DIPUjoCh.d.mts +2 -0
- package/dist/platform-C3Q44RJ8.mjs +250 -0
- package/dist/platform-args-BSyVZESg.mjs +1 -0
- package/dist/{platform-args-CvZSuhYS.mjs → platform-args-BnocJDC_.mjs} +1 -1
- package/dist/{platform-auth-config-CpszX-Ne.mjs → platform-auth-config-BbfNhjBc.mjs} +9 -9
- package/dist/{platform-auth-protection-DA6Tw8Og.mjs → platform-auth-protection-BHPV4MUf.mjs} +9 -8
- package/dist/{platform-auth-recovery-Cztrb1JC.mjs → platform-auth-recovery-DE0nArYy.mjs} +8 -7
- package/dist/{platform-cmd-m6Asj6nO.mjs → platform-cmd-CLRU3BRb.mjs} +11 -10
- package/dist/{platform-cmd-u1j88ggF.mjs → platform-cmd-Cs2LkT5L.mjs} +1 -1
- package/dist/{platform-discovery-CLxtixHJ.mjs → platform-discovery-CKeeeD82.mjs} +1 -1
- package/dist/{platform-domain-DJSznNTA.mjs → platform-domain-kn3WuKPG.mjs} +6 -5
- package/dist/{platform-lifecycle-BC-9p58d.mjs → platform-lifecycle-BoCEYy2w.mjs} +1 -1
- package/dist/{platform-lifecycle-GFeXv3NC.mjs → platform-lifecycle-CKwOg8wz.mjs} +244 -104
- package/dist/{platform-management-BwHkz46V.mjs → platform-management-CaSdFthX.mjs} +1 -1
- package/dist/{platform-management-DX1zINou.mjs → platform-management-fyrsq2Ra.mjs} +27 -14
- package/dist/{platform-plans-config-DiydtNKY.mjs → platform-plans-config-BSI-6Inu.mjs} +11 -5
- package/dist/{platform-recovery-CnzBbudV.mjs → platform-recovery-PwJ54AIZ.mjs} +3 -3
- package/dist/{platform-registry-DHH6fivm.mjs → platform-registry-zHH3RiIm.mjs} +2 -1
- package/dist/{platform-setup-Lph9i-rh.mjs → platform-setup-DwYITHfY.mjs} +3 -3
- package/dist/{plugin-inference-COlq96WJ.mjs → plugin-inference-D5MjBVMB.mjs} +60 -142
- package/dist/prepare-CLl_TA_r.mjs +1 -0
- package/dist/{prepare-WvijE289.mjs → prepare-DZEs5AGr.mjs} +3 -3
- package/dist/{prepare-co1o1FFd.mjs → prepare-DhVzN7CB.mjs} +14 -12
- package/dist/{project-uXKua1it.mjs → project-BXpm-vgG.mjs} +1 -1
- package/dist/{project-dh9431bN.mjs → project-DC-BqHef.mjs} +1 -1
- package/dist/{project-cmd-BWJTplpc.mjs → project-cmd-BKN3qT4R.mjs} +31 -21
- package/dist/{project-paths-2ENfCCih.mjs → project-paths-BeAxxqGh.mjs} +1 -1
- package/dist/{project-security-BV1xfj1K.mjs → project-security-B-SHxprt.mjs} +1 -1
- package/dist/{project-security-CY_aahvW.mjs → project-security-BWTd6cTU.mjs} +87 -46
- package/dist/{project-team-BlIFXlmT.mjs → project-team-jcn9reIB.mjs} +6 -6
- package/dist/{project-token-CMsB7I1-.mjs → project-token-BHkBKtzt.mjs} +6 -6
- package/dist/{project-tsconfig-BOA4ym99.mjs → project-tsconfig-LjgxDdj_.mjs} +1 -1
- package/dist/{project-zero-trust-BI6pdpx4.mjs → project-zero-trust-2t_qI6xa.mjs} +4 -4
- package/dist/{protocol-4rEnumif.mjs → protocol-DhMbnxzy.mjs} +120 -35
- package/dist/{protocol-ERy-n3jf.d.mts → protocol-wG7JP5Mm.d.mts} +27 -4
- package/dist/{provision-DFv7SJDn.mjs → provision-C04aXE3a.mjs} +1 -1
- package/dist/{provision-Bh44omGA.mjs → provision-CQykn8gu.mjs} +8 -4
- package/dist/{redirect-Dyvuil0Q.mjs → redirect-DjyA_hx_.mjs} +1 -1
- package/dist/{requests-CfmJxNYg.mjs → requests-BznxnxTT.mjs} +5 -5
- package/dist/resolve-project-Bob_rEi2.mjs +1 -0
- package/dist/{resolve-project-8WZ3iVmr.mjs → resolve-project-s_FGWyr-.mjs} +2 -2
- package/dist/resource-binding-5nI30acw.mjs +20 -0
- package/dist/{resource-name-DlJ9QXzg.mjs → resource-name-D_gw36kh.mjs} +5 -1
- package/dist/{rollback-DL5HuAsM.mjs → rollback-CLiINtpt.mjs} +25 -14
- package/dist/{route-types-CSed9-Dp.mjs → route-types-DxvqN5bL.mjs} +59 -9
- package/dist/{route-url-B41eQ8QI.mjs → route-url-CRC8yR_2.mjs} +2 -3
- package/dist/{route-url-Bd6IX-JZ.d.mts → route-url-zDfC-7DD.d.mts} +33 -5
- package/dist/routes-stub.d.mts +18 -2
- package/dist/routes-stub.mjs +1 -1
- package/dist/{runner-CeguHWJx.mjs → runner-CnUrhc8H.mjs} +1 -1
- package/dist/{runner-mysql-DOjbj-N1.mjs → runner-mysql-CW6bFa67.mjs} +1 -1
- package/dist/{runner-mysql-D549vGGm.mjs → runner-mysql-DSLGFOlC.mjs} +1 -1
- package/dist/{runner-pg-Buzw17hl.mjs → runner-pg-BcGF7iBR.mjs} +1 -1
- package/dist/{runner-pg-DMJquR3d.mjs → runner-pg-OeP0JpEo.mjs} +1 -1
- package/dist/{runner-Bf94YVJK.mjs → runner-rnXCGa20.mjs} +1 -1
- package/dist/runtime/ai/index.mjs +1 -1
- package/dist/runtime/auth/better-auth-d1.d.mts +1 -1
- package/dist/runtime/auth/better-auth-mysql.d.mts +1 -1
- package/dist/runtime/auth/better-auth-postgres.d.mts +1 -1
- package/dist/runtime/client/fetch-server.mjs +1 -1
- package/dist/runtime/client/fetch-stream.mjs +1 -1
- package/dist/runtime/client/fetch.mjs +1 -1
- package/dist/runtime/client/index.mjs +2 -2
- package/dist/runtime/client/react.mjs +2 -2
- package/dist/runtime/client/solid.mjs +2 -2
- package/dist/runtime/client/svelte.mjs +2 -2
- package/dist/runtime/client/vue.mjs +2 -2
- package/dist/runtime/durable/index.mjs +11 -26
- package/dist/runtime/env/runtime.d.mts +2 -10
- package/dist/runtime/handler/index.d.mts +3 -2
- package/dist/runtime/handler/index.mjs +2 -2
- package/dist/runtime/handler/validator.d.mts +1 -1
- package/dist/runtime/handler/validator.mjs +1 -1
- package/dist/runtime/html.d.mts +2 -0
- package/dist/runtime/html.mjs +1 -0
- package/dist/runtime/image/index.d.mts +103 -0
- package/dist/runtime/image/index.mjs +89 -0
- package/dist/runtime/jsx/index.d.mts +3 -0
- package/dist/runtime/jsx/index.mjs +2 -0
- package/dist/runtime/jsx/jsx-dev-runtime.d.mts +1 -0
- package/dist/runtime/jsx/jsx-dev-runtime.mjs +2 -0
- package/dist/runtime/jsx/jsx-runtime.d.mts +1 -0
- package/dist/runtime/jsx/jsx-runtime.mjs +2 -0
- package/dist/runtime/limits/index.mjs +1 -1
- package/dist/runtime/live/client.d.mts +2 -2
- package/dist/runtime/live/index.d.mts +1 -1
- package/dist/runtime/routing/index.d.mts +87 -4
- package/dist/runtime/routing/index.mjs +59 -20
- package/dist/runtime/routing/route-url.d.mts +2 -2
- package/dist/runtime/routing/route-url.mjs +1 -1
- package/dist/runtime/sandbox/index.mjs +1 -1
- package/dist/runtime/sse/client.d.mts +1 -1
- package/dist/runtime/workflows/entry.d.mts +8 -0
- package/dist/runtime/workflows/entry.mjs +49 -0
- package/dist/runtime/workflows/index.d.mts +3 -0
- package/dist/runtime/workflows/index.mjs +77 -0
- package/dist/runtime/ws/index.d.mts +1 -1
- package/dist/runtime/ws/index.mjs +2 -2
- package/dist/runtime/ws/room.d.mts +1 -1
- package/dist/runtime/ws/server.d.mts +2 -2
- package/dist/runtime-Db72hLY-.d.mts +11 -0
- package/dist/scan-BxhB4BA-.mjs +946 -0
- package/dist/scan-D2ISAobj.mjs +308 -0
- package/dist/{secret-C-WBaUSS.mjs → secret-Ck9N5xbU.mjs} +9 -8
- package/dist/{security-sarif-ClyYwtAW.mjs → security-sarif-DzTIqNwZ.mjs} +1 -1
- package/dist/{serialize-DN-envGQ.d.mts → serialize-Dr9B-0yV.d.mts} +10 -1
- package/dist/{serialize-BmB4BfKu.mjs → serialize-nW4IeEBI.mjs} +23 -2
- package/dist/{skills-C-csz78e.mjs → skills-BR7YHAF7.mjs} +1 -1
- package/dist/{scan-Ct_SEzH4.mjs → source-analysis-cache-Ccm_JSOl.mjs} +340 -902
- package/dist/standard-schema-DvMcZGMK.mjs +8 -0
- package/dist/{subcommand-prompt-B4LOLosl.mjs → subcommand-prompt-AFf2LcrC.mjs} +2 -2
- package/dist/{types-FDH6NuY1.d.mts → types-RYVujNS6.d.mts} +4 -2
- package/dist/{version-metadata-DqgLa6gc.mjs → untrusted-env-4oW0TdBP.mjs} +1 -23
- package/dist/{url-DBQluotE.mjs → url-DAQ1c3lh.mjs} +45 -1
- package/dist/{validate-CtBWCzez.mjs → validate-B1PsQ_mt.mjs} +1 -1
- package/dist/validate-p9b3r1k4.mjs +1 -0
- package/dist/{validation-error-CtcAvyI7.mjs → validation-error-EKI0wMWX.mjs} +2 -2
- package/dist/{validator-Dfh9kCDm.mjs → validator-JJcf9E48.mjs} +5 -8
- package/dist/version-metadata-CEla0kgi.mjs +23 -0
- package/dist/{wrangler-DVe5KV5G.mjs → wrangler-AyMfdVJK.mjs} +34 -69
- package/dist/wrangler-BT7qrzWc.mjs +1 -0
- package/dist/{wrapper-CcMYpOS8.mjs → wrapper-DPlTBVOx.mjs} +5 -5
- package/docs/guide/ai.md +1 -1
- package/docs/guide/app-types.md +6 -23
- package/docs/guide/auth.md +2 -4
- package/docs/guide/database/d1.md +21 -67
- package/docs/guide/database/mysql.md +8 -0
- package/docs/guide/database/postgresql.md +2 -2
- package/docs/guide/database.md +1 -1
- package/docs/guide/deployment.md +18 -0
- package/docs/guide/edge/prerendering.md +3 -7
- package/docs/guide/edge/redirects.md +1 -1
- package/docs/guide/edge/revalidation.md +8 -17
- package/docs/guide/edge/rewrites.md +1 -1
- package/docs/guide/edge/static-assets.md +10 -22
- package/docs/guide/email/domains.md +3 -1
- package/docs/guide/email/receiving.md +2 -2
- package/docs/guide/email/sending.md +3 -1
- package/docs/guide/env-vars.md +2 -0
- package/docs/guide/image-generation.md +142 -0
- package/docs/guide/index.md +17 -15
- package/docs/guide/jobs.md +2 -4
- package/docs/guide/kv.md +1 -1
- package/docs/guide/og-images.md +83 -0
- package/docs/guide/pages-routing/actions-and-forms.md +6 -4
- package/docs/guide/pages-routing/errors.md +20 -4
- package/docs/guide/pages-routing/head.md +5 -5
- package/docs/guide/pages-routing/islands.md +4 -14
- package/docs/guide/pages-routing/markdown.md +2 -2
- package/docs/guide/pages-routing/overview.md +129 -15
- package/docs/guide/platform/administration/plans.md +47 -16
- package/docs/guide/platform/administration/projects.md +10 -0
- package/docs/guide/platform/administration/security-audits.md +76 -30
- package/docs/guide/platform/administration/zero-trust.md +1 -1
- package/docs/guide/platform/installation/ci.md +0 -4
- package/docs/guide/platform/installation/credentials.md +1 -1
- package/docs/guide/platform/installation/maintenance.md +11 -9
- package/docs/guide/platform/installation/prerequisites.md +3 -1
- package/docs/guide/platform/installation/setup.md +7 -15
- package/docs/guide/platform/installation/uninstall.md +6 -12
- package/docs/guide/project-collaboration.md +1 -4
- package/docs/guide/queues.md +6 -8
- package/docs/guide/quickstart.md +6 -8
- package/docs/guide/sandboxes.md +1 -1
- package/docs/guide/self-hosted-platform.md +4 -7
- package/docs/guide/server-routing.md +5 -3
- package/docs/guide/ssg.md +1 -1
- package/docs/guide/type-safety.md +74 -10
- package/docs/guide/websockets.md +5 -7
- package/docs/guide/workflows.md +122 -0
- package/docs/index.md +2 -3
- package/docs/integrations/agents.md +3 -16
- package/docs/integrations/cloudflare.md +98 -2
- package/docs/integrations/frameworks/analog.md +9 -11
- package/docs/integrations/frameworks/astro.md +16 -17
- package/docs/integrations/frameworks/nuxt.md +11 -13
- package/docs/integrations/frameworks/overview.md +18 -20
- package/docs/integrations/frameworks/react-router.md +55 -6
- package/docs/integrations/frameworks/sveltekit.md +8 -6
- package/docs/integrations/frameworks/tanstack-start.md +10 -6
- package/docs/integrations/hono.md +27 -12
- package/docs/integrations/nodejs-bun-deno.md +10 -2
- package/docs/reference/api/database.md +8 -10
- package/docs/reference/api/env.md +2 -2
- package/docs/reference/api/handlers.md +1 -1
- package/docs/reference/api/html.md +45 -0
- package/docs/reference/api/pages.md +118 -167
- package/docs/reference/api/rewrites.md +5 -5
- package/docs/reference/api/types.md +13 -6
- package/docs/reference/api/workflows.md +48 -0
- package/docs/reference/api.md +7 -1
- package/docs/reference/cli/database.md +22 -10
- package/docs/reference/cli/deploy.md +49 -4
- package/docs/reference/cli/domains.md +7 -3
- package/docs/reference/cli/email.md +3 -1
- package/docs/reference/cli/platform-installation.md +9 -53
- package/docs/reference/cli/platform-security.md +36 -8
- package/docs/reference/cli/platform-users.md +11 -1
- package/docs/reference/cli/platform-zero-trust.md +1 -1
- package/docs/reference/cli/project.md +52 -11
- package/docs/reference/cli/setup.md +8 -10
- package/docs/reference/cli.md +49 -47
- package/docs/reference/config.md +22 -8
- package/docs/reference/resource-inference.md +8 -1
- package/docs/reference/structure.md +5 -0
- package/package.json +52 -25
- package/schema.json +20 -1
- package/skills/void/SKILL.md +60 -54
- package/dist/cf-build-output-Wpk_e5CI.mjs +0 -1
- package/dist/cf-worker-settings-BBdlhm9U.mjs +0 -41
- package/dist/cli/db-execute-process.d.mts +0 -2
- package/dist/cli/db-execute-process.mjs +0 -57
- package/dist/cloudflare-user-output-CCR99eQY.mjs +0 -19
- package/dist/collect-B6nlSnsb.mjs +0 -1
- package/dist/db-args-BvMwAber.mjs +0 -1
- package/dist/deploy-Do6FWqon.mjs +0 -2
- package/dist/discover-D2KGP3cR.mjs +0 -1
- package/dist/entry-Bwb9ev8K.mjs +0 -113
- package/dist/gen-vhBDHs3q.mjs +0 -1
- package/dist/help-fKPzcTJv.mjs +0 -1
- package/dist/isr-config-DiTnL9Tb.mjs +0 -115
- package/dist/login-DECm3e9b.mjs +0 -1
- package/dist/migrate-C9aoWLvY.mjs +0 -1
- package/dist/operator-cmd-CVfK5U0B.mjs +0 -1
- package/dist/output-D7K9TWIA.mjs +0 -1
- package/dist/platform-args-CMwMoiLp.mjs +0 -1
- package/dist/prepare-DcwigRUS.mjs +0 -1
- package/dist/providers-D5P8j_8D.d.mts +0 -5
- package/dist/resolve-project-YsTH-U9I.mjs +0 -1
- package/dist/static-exports-s7P86Ngp.mjs +0 -354
- package/dist/validate-CZYUIfR-.mjs +0 -1
- package/dist/wrangler-Dq269bjx.mjs +0 -1
- package/docs/guide/platform/development/local.md +0 -120
- package/docs/guide/platform/development/runtime.md +0 -115
- package/docs/guide/platform/development/schema-ci.md +0 -44
- package/docs/guide/platform-development.md +0 -16
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { t as HtmlEscapedString } from "../../html-5sfGLjiI.mjs";
|
|
2
|
+
import { JSXNode } from "hono/jsx";
|
|
3
|
+
type BrowserRunFontData = ImageFontBytes | ImageFontUrl;
|
|
4
|
+
declare const genericFamilies: readonly ["serif", "sans-serif", "monospace", "cursive", "fantasy"];
|
|
5
|
+
/** Preinstalled families: https://developers.cloudflare.com/browser-run/reference/supported-fonts/ */
|
|
6
|
+
type BrowserRunDefaultFontFamily = (typeof genericFamilies)[number] | "Andale Mono" | "Arial" | "Arial Black" | "Comic Sans MS" | "Courier" | "Courier New" | "Georgia" | "Helvetica" | "Impact" | "Lucida Handwriting" | "Times" | "Times New Roman" | "Trebuchet MS" | "Verdana" | "Webdings" | `Bitstream Vera ${"Serif" | "Sans" | "Sans Mono"}` | "Bitstream Cyberbit" | "Cyberbit" | `DejaVu ${"Serif" | "Sans" | "Sans Mono"}` | `Free${"Serif" | "Sans" | "Mono"}` | "GFS Neohellenic" | `Liberation ${"Serif" | "Sans" | "Mono"}` | "Open Sans" | "Roboto" | "IPAGothic" | "IPAPGothic" | "Lohit Devanagari" | "Lohit Bengali" | "Lohit Tamil" | `Kacst${"Art" | "Book" | "Decorative" | "Digital" | "Farsi" | "Letter" | "Naskh" | "Office" | "One" | "Pen" | "Poster" | "Qurn" | "Screen" | "Title" | "TitleL"}` | `Noto ${"Sans" | "Serif"} CJK ${"HK" | "JP" | "KR" | "SC" | "TC"}` | "Noto Color Emoji" | "Garuda" | "Kinnari" | "Laksaman" | "Loma" | "Norasi" | "Purisa" | "Sawasdee" | `Tlwg ${"Mono" | "Typewriter" | "Typist" | "Typo"}` | "Umpush" | "Waree" | "WenQuanYi Zen Hei";
|
|
7
|
+
/** The default renderer uses the Worker binding directly, without a browser SDK. */
|
|
8
|
+
declare const browserRunRenderer: ImageRenderer<BrowserRunDefaultFontFamily, BrowserRunFontData>;
|
|
9
|
+
/** Encoded font-file bytes. */
|
|
10
|
+
type ImageFontBytes = ArrayBuffer | Uint8Array;
|
|
11
|
+
/** A remote font file. */
|
|
12
|
+
interface ImageFontUrl {
|
|
13
|
+
url: string;
|
|
14
|
+
}
|
|
15
|
+
/** A named font face with a source supported by the selected renderer. */
|
|
16
|
+
interface ImageFont<FontFamily extends string, RendererFontData> {
|
|
17
|
+
name: FontFamily;
|
|
18
|
+
/**
|
|
19
|
+
* The weight the font draws, from 1 to 1000. Leave it out for a variable
|
|
20
|
+
* font, so each element's `fontWeight` sets the weight; with it, the font
|
|
21
|
+
* draws only this weight.
|
|
22
|
+
*/
|
|
23
|
+
weight?: number;
|
|
24
|
+
style?: "normal" | "italic";
|
|
25
|
+
/**
|
|
26
|
+
* Accepted for compatibility. Set the render's `lang` or the root element's
|
|
27
|
+
* `lang` attribute to choose how Chinese characters are drawn.
|
|
28
|
+
*/
|
|
29
|
+
lang?: string;
|
|
30
|
+
data: RendererFontData;
|
|
31
|
+
}
|
|
32
|
+
/** Hono JSX or an escaped HTML template from `void/html`. */
|
|
33
|
+
type ImageInput = JSXNode | HtmlEscapedString | Promise<HtmlEscapedString>;
|
|
34
|
+
type AnyImageRenderer = ImageRenderer<never, never, never>;
|
|
35
|
+
type DefaultImageRenderer = typeof browserRunRenderer;
|
|
36
|
+
type RendererSettings<Renderer extends AnyImageRenderer> = Renderer extends ImageRenderer<infer DefaultFontFamily, infer FontData, never> ? {
|
|
37
|
+
defaultFontFamily: DefaultFontFamily;
|
|
38
|
+
fontData: FontData;
|
|
39
|
+
} : never;
|
|
40
|
+
type SharedSettingKey = keyof ImageRenderSettings<string, string, unknown>;
|
|
41
|
+
/**
|
|
42
|
+
* Selects a renderer, optionally with its own options. A renderer with required
|
|
43
|
+
* options must be passed in a tuple; renderer options cannot repeat shared
|
|
44
|
+
* settings such as `width`, which would replace them.
|
|
45
|
+
*/
|
|
46
|
+
type ImageRendererOption<Renderer extends AnyImageRenderer> = (Record<never, never> extends RendererOptions<Renderer> ? Renderer : never) | [Renderer, NoInfer<RendererOptions<Renderer>> & { [Key in SharedSettingKey]?: never; }];
|
|
47
|
+
/** The renderer's own options, read from its signature without the shared settings. */
|
|
48
|
+
type RendererOptions<Renderer extends AnyImageRenderer> = Renderer extends ((element: ImageInput, options: infer Options) => unknown) ? Options extends unknown ? Omit<Options, SharedSettingKey> : never : never;
|
|
49
|
+
type IsDefaultRenderer<Renderer extends AnyImageRenderer> = [Renderer] extends [DefaultImageRenderer] ? [DefaultImageRenderer] extends [Renderer] ? true : false : false;
|
|
50
|
+
/** Only the default renderer may be omitted; other renderers type fonts differently. */
|
|
51
|
+
type RendererSelection<Renderer extends AnyImageRenderer> = IsDefaultRenderer<Renderer> extends true ? {
|
|
52
|
+
/** Defaults to Cloudflare Browser Run using the BROWSER binding. */
|
|
53
|
+
renderer?: ImageRendererOption<Renderer>;
|
|
54
|
+
} : {
|
|
55
|
+
/** Defaults to Cloudflare Browser Run using the BROWSER binding. */
|
|
56
|
+
renderer: ImageRendererOption<Renderer>;
|
|
57
|
+
};
|
|
58
|
+
/** The shared settings typed for a renderer's fonts. */
|
|
59
|
+
type RendererRenderSettings<Renderer extends AnyImageRenderer, FontFamily extends string> = ImageRenderSettings<RendererSettings<Renderer>["defaultFontFamily"], FontFamily, RendererSettings<Renderer>["fontData"]>;
|
|
60
|
+
/** Rendering options, without HTTP response options. */
|
|
61
|
+
type RenderImageOptions<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never> = RendererRenderSettings<Renderer, FontFamily> & RendererSelection<Renderer>;
|
|
62
|
+
interface ImageRenderSettings<RendererDefaultFontFamily extends string, FontFamily extends string, RendererFontData> {
|
|
63
|
+
width: number;
|
|
64
|
+
height: number;
|
|
65
|
+
/** Language of the text, such as `ja` or `zh-TW`. */
|
|
66
|
+
lang?: string;
|
|
67
|
+
/** Draws a border around every box. */
|
|
68
|
+
debug?: boolean;
|
|
69
|
+
/** Default font family or ordered fallback stack. */
|
|
70
|
+
font?: NoInfer<RendererDefaultFontFamily | FontFamily | Array<RendererDefaultFontFamily | FontFamily>>;
|
|
71
|
+
/** Custom font faces. Browser Run requires a name with an HTTPS file URL or bytes. */
|
|
72
|
+
fonts?: Array<ImageFont<FontFamily, RendererFontData>>;
|
|
73
|
+
}
|
|
74
|
+
/** Takes the original image input and returns encoded PNG bytes. */
|
|
75
|
+
type ImageRenderer<RendererDefaultFontFamily extends string, RendererFontData, RendererOptions = undefined> = <FontFamily extends string>(element: ImageInput, options: ImageRenderSettings<RendererDefaultFontFamily, FontFamily, RendererFontData> & (RendererOptions extends Record<never, never> ? RendererOptions : Record<never, never>)) => Promise<Uint8Array<ArrayBuffer>>;
|
|
76
|
+
/** Renders Hono JSX or an escaped HTML template to PNG bytes. */
|
|
77
|
+
export declare function renderImage<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never>(element: ImageInput, options: RenderImageOptions<Renderer, FontFamily>): Promise<Uint8Array<ArrayBuffer>>;
|
|
78
|
+
/** Open Graph rendering options, with default dimensions of 1200 × 630. */
|
|
79
|
+
type RenderOgImageOptions<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never> = Omit<RendererRenderSettings<Renderer, FontFamily>, "width" | "height"> & {
|
|
80
|
+
/** Image width in pixels. Defaults to 1200. */
|
|
81
|
+
width?: number;
|
|
82
|
+
/** Image height in pixels. Defaults to 630. */
|
|
83
|
+
height?: number;
|
|
84
|
+
} & RendererSelection<Renderer>;
|
|
85
|
+
/** Renders PNG bytes at 1200 × 630 by default, or with custom dimensions. */
|
|
86
|
+
export declare function renderOgImage<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never>(element: ImageInput, options?: RenderOgImageOptions<Renderer, FontFamily>): Promise<Uint8Array<ArrayBuffer>>;
|
|
87
|
+
/** Image rendering options combined with the response status and headers. */
|
|
88
|
+
type ImageResponseOptions<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never> = ResponseInit & RenderImageOptions<Renderer, FontFamily>;
|
|
89
|
+
/**
|
|
90
|
+
* A PNG response rendered when its body is read. Use `renderImage` to await
|
|
91
|
+
* completion and handle rendering errors before creating an HTTP response.
|
|
92
|
+
* Does not choose a cache policy.
|
|
93
|
+
*/
|
|
94
|
+
export declare class ImageResponse<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never> extends Response {
|
|
95
|
+
constructor(element: ImageInput, options: ImageResponseOptions<Renderer, FontFamily>);
|
|
96
|
+
}
|
|
97
|
+
/** Open Graph rendering options combined with the response status and headers. */
|
|
98
|
+
type OgImageResponseOptions<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never> = RenderOgImageOptions<Renderer, FontFamily> & ResponseInit;
|
|
99
|
+
/** A lazy PNG response: 1200 × 630 by default, with a 24-hour public cache default outside dev. */
|
|
100
|
+
export declare class OgImageResponse<Renderer extends AnyImageRenderer = DefaultImageRenderer, FontFamily extends string = never> extends ImageResponse<Renderer, FontFamily> {
|
|
101
|
+
constructor(element: ImageInput, options?: OgImageResponseOptions<Renderer, FontFamily>);
|
|
102
|
+
}
|
|
103
|
+
export type { BrowserRunDefaultFontFamily, BrowserRunFontData, DefaultImageRenderer, ImageFont, ImageFontBytes, ImageFontUrl, ImageInput, ImageRenderer, ImageResponseOptions, OgImageResponseOptions, RenderImageOptions, RenderOgImageOptions };
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { n as prepareImageInput } from "../../input-jcps6lAn.mjs";
|
|
2
|
+
import { AsyncLocalStorage } from "node:async_hooks";
|
|
3
|
+
// src/runtime/image/generate/render-image.ts
|
|
4
|
+
/** Renders Hono JSX or an escaped HTML template to PNG bytes. */
|
|
5
|
+
async function renderImage(element, options) {
|
|
6
|
+
const input = prepareImageInput(element);
|
|
7
|
+
const { renderer: selection, ...renderOptions } = options;
|
|
8
|
+
if (!selection) {
|
|
9
|
+
const { browserRunRenderer } = await import("../../browser-run-BKgZVwLk.mjs");
|
|
10
|
+
return browserRunRenderer(input, {
|
|
11
|
+
...renderOptions,
|
|
12
|
+
fonts: renderOptions.fonts
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
const [renderer, rendererOptions] = typeof selection === "function" ? [selection, void 0] : selection;
|
|
16
|
+
return renderer(input, Object.assign({}, rendererOptions, renderOptions));
|
|
17
|
+
}
|
|
18
|
+
/** Renders PNG bytes at 1200 × 630 by default, or with custom dimensions. */
|
|
19
|
+
async function renderOgImage(element, options = {}) {
|
|
20
|
+
return renderImage(element, resolveOgImageOptions(options));
|
|
21
|
+
}
|
|
22
|
+
/** Shared by the byte API and lazy response wrapper. */
|
|
23
|
+
function resolveOgImageOptions(options) {
|
|
24
|
+
return {
|
|
25
|
+
...options,
|
|
26
|
+
width: options.width ?? 1200,
|
|
27
|
+
height: options.height ?? 630
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
// src/runtime/image/generate/image-response.ts
|
|
31
|
+
/**
|
|
32
|
+
* A PNG response rendered when its body is read. Use `renderImage` to await
|
|
33
|
+
* completion and handle rendering errors before creating an HTTP response.
|
|
34
|
+
* Does not choose a cache policy.
|
|
35
|
+
*/
|
|
36
|
+
var ImageResponse = class extends Response {
|
|
37
|
+
constructor(element, options) {
|
|
38
|
+
const { status, statusText, headers: responseHeaders, ...rest } = options;
|
|
39
|
+
const imageOptions = rest;
|
|
40
|
+
const headers = new Headers(responseHeaders);
|
|
41
|
+
if (!headers.has("content-type")) headers.set("content-type", "image/png");
|
|
42
|
+
const input = prepareImageInput(element);
|
|
43
|
+
const inRequestScope = AsyncLocalStorage.snapshot();
|
|
44
|
+
super(lazyImageBody(() => inRequestScope(() => renderImage(input, imageOptions))), {
|
|
45
|
+
status,
|
|
46
|
+
statusText,
|
|
47
|
+
headers
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
function lazyImageBody(render) {
|
|
52
|
+
let started = false;
|
|
53
|
+
let cancelled = false;
|
|
54
|
+
return new ReadableStream({
|
|
55
|
+
async pull(controller) {
|
|
56
|
+
if (started || cancelled) return;
|
|
57
|
+
started = true;
|
|
58
|
+
try {
|
|
59
|
+
const image = await render();
|
|
60
|
+
if (cancelled) return;
|
|
61
|
+
controller.enqueue(image);
|
|
62
|
+
controller.close();
|
|
63
|
+
} catch (error) {
|
|
64
|
+
if (cancelled) return;
|
|
65
|
+
console.error("void/image: failed to render the image.", error);
|
|
66
|
+
controller.error(error);
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
cancel() {
|
|
70
|
+
cancelled = true;
|
|
71
|
+
}
|
|
72
|
+
}, { highWaterMark: 0 });
|
|
73
|
+
}
|
|
74
|
+
/** A lazy PNG response: 1200 × 630 by default, with a 24-hour public cache default outside dev. */
|
|
75
|
+
var OgImageResponse = class extends ImageResponse {
|
|
76
|
+
constructor(element, options = {}) {
|
|
77
|
+
const { status, statusText, headers, ...rest } = options;
|
|
78
|
+
const imageOptions = rest;
|
|
79
|
+
const responseHeaders = new Headers(headers);
|
|
80
|
+
if (!import.meta.env?.DEV && !responseHeaders.has("cache-control")) responseHeaders.set("cache-control", "public, max-age=86400");
|
|
81
|
+
super(element, {
|
|
82
|
+
...resolveOgImageOptions(imageOptions),
|
|
83
|
+
status,
|
|
84
|
+
statusText,
|
|
85
|
+
headers: responseHeaders
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
};
|
|
89
|
+
export { ImageResponse, OgImageResponse, renderImage, renderOgImage };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "hono/jsx/jsx-dev-runtime";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "hono/jsx/jsx-runtime";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as UsageLimit, n as asUsageLimit, r as limitFromResponse, i as readUsageLimit } from "../../limits-
|
|
1
|
+
export { t as UsageLimit, n as asUsageLimit, r as limitFromResponse, i as readUsageLimit } from "../../limits-3I3VdX2E.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as RequestUrl } from "../../route-url-
|
|
2
|
-
import { t as LiveClientEvent } from "../../index-
|
|
1
|
+
import { n as RequestUrl } from "../../route-url-zDfC-7DD.mjs";
|
|
2
|
+
import { t as LiveClientEvent } from "../../index-lnEWwVAS.mjs";
|
|
3
3
|
export type LiveSubscribeOptions<Data = unknown> = {
|
|
4
4
|
id: string;
|
|
5
5
|
topic: string;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/// <reference types="@cloudflare/workers-types" />
|
|
2
|
-
import { _ as __getLiveBindingName, a as LiveControlErrorCode, b as defineLiveStream, c as LiveControlOptions, d as LiveHookContext, f as LiveLimits, g as LiveSubscribeHookContext, h as LiveStreamOptions, i as LiveControlError, l as LiveControlRequest, m as LiveStream, n as LiveConnectHookContext, o as LiveControlOperation, p as LivePublishOptions, r as LiveConnectOptions, s as LiveControlOperationResult, t as LiveClientEvent, u as LiveControlResponse, v as __setLiveBindingName, y as __setLiveDev } from "../../index-
|
|
2
|
+
import { _ as __getLiveBindingName, a as LiveControlErrorCode, b as defineLiveStream, c as LiveControlOptions, d as LiveHookContext, f as LiveLimits, g as LiveSubscribeHookContext, h as LiveStreamOptions, i as LiveControlError, l as LiveControlRequest, m as LiveStream, n as LiveConnectHookContext, o as LiveControlOperation, p as LivePublishOptions, r as LiveConnectOptions, s as LiveControlOperationResult, t as LiveClientEvent, u as LiveControlResponse, v as __setLiveBindingName, y as __setLiveDev } from "../../index-lnEWwVAS.mjs";
|
|
3
3
|
export { LiveClientEvent, LiveConnectHookContext, LiveConnectOptions, LiveControlError, LiveControlErrorCode, LiveControlOperation, LiveControlOperationResult, LiveControlOptions, LiveControlRequest, LiveControlResponse, LiveHookContext, LiveLimits, LivePublishOptions, LiveStream, LiveStreamOptions, LiveSubscribeHookContext, __getLiveBindingName, __setLiveBindingName, __setLiveDev, defineLiveStream };
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a as handlePageMutation, i as handlePageGet } from "../../protocol-
|
|
1
|
+
import { n as CloudContext } from "../../index-CqF8_p9C.mjs";
|
|
2
|
+
import { a as handlePageMutation, i as handlePageGet } from "../../protocol-wG7JP5Mm.mjs";
|
|
3
|
+
import { t as StandardSchemaV1 } from "../../standard-schema-CuDawHOC.mjs";
|
|
4
|
+
import { t as DevCssAsset } from "../../types-RYVujNS6.mjs";
|
|
5
|
+
import { t as AssetBinding } from "../../bindings-C7zOgxT3.mjs";
|
|
3
6
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
4
|
-
import { Context, Hono, Hono as Hono$1, MiddlewareHandler, NotFoundHandler, TypedResponse } from "hono";
|
|
7
|
+
import { Context, ExecutionContext, Hono, Hono as Hono$1, MiddlewareHandler, NotFoundHandler, TypedResponse } from "hono";
|
|
5
8
|
import { matchedRoutes, matchedRoutes as matchedRoutes$1 } from "hono/route";
|
|
6
9
|
import { RouteDestination, RouteUrlInput } from "void/routes";
|
|
7
10
|
import { RedirectStatusCode } from "hono/utils/http-status";
|
|
@@ -18,12 +21,88 @@ type ErrorRenderer = {
|
|
|
18
21
|
};
|
|
19
22
|
/** Error rendering is shared by generated Pages apps; production never includes exception details. */
|
|
20
23
|
export declare function createErrorRenderer(options: ErrorRendererOptions): ErrorRenderer;
|
|
24
|
+
type ClientManifest = Record<string, {
|
|
25
|
+
file?: string;
|
|
26
|
+
imports?: Array<string>;
|
|
27
|
+
css?: Array<string>;
|
|
28
|
+
/** Build-proven fingerprinted outputs; absent in older/third-party manifests. */
|
|
29
|
+
immutableFiles?: Array<string>;
|
|
30
|
+
}>;
|
|
31
|
+
type RuntimeEnvironment = Record<string, unknown> & {
|
|
32
|
+
ASSETS?: AssetBinding;
|
|
33
|
+
};
|
|
34
|
+
type AssetFallbackOptions = {
|
|
35
|
+
assetsDir?: string;
|
|
36
|
+
serveSpaFallback?: boolean;
|
|
37
|
+
notFound?: "none" | "404-page" | "single-page-application";
|
|
38
|
+
};
|
|
39
|
+
export declare function createAssetFallback(options?: AssetFallbackOptions): (request: Request, env: RuntimeEnvironment, response: Response) => Promise<Response>;
|
|
40
|
+
/** Hide platform capabilities without copying bindings or changing application bindings. */
|
|
41
|
+
export declare function filterInternalBindings<E extends Record<string, unknown>>(env: E, prefixes: Array<string>, exactNames?: Array<string>): E;
|
|
42
|
+
type WorkerFetchOptions = {
|
|
43
|
+
app: {
|
|
44
|
+
fetch: (request: Request, env: RuntimeEnvironment, context: ExecutionContext) => Response | Promise<Response>;
|
|
45
|
+
};
|
|
46
|
+
assets: ReturnType<typeof createAssetFallback>;
|
|
47
|
+
withRawEnv: (env: RuntimeEnvironment, fn: () => Promise<Response>) => Promise<Response>;
|
|
48
|
+
withRuntimeEnv: (env: RuntimeEnvironment, fn: () => Promise<Response>) => Promise<Response>;
|
|
49
|
+
filterBindings: (env: RuntimeEnvironment) => RuntimeEnvironment;
|
|
50
|
+
validateEnv?: (env: RuntimeEnvironment) => Promise<void>;
|
|
51
|
+
/** Native Cloudflare production builds redirect public HTTP requests to HTTPS. */
|
|
52
|
+
alwaysUseHttps?: boolean;
|
|
53
|
+
/** Authored/generated version metadata binding used to prove the served native version. */
|
|
54
|
+
versionMetadataBinding?: string;
|
|
55
|
+
remoteEnv?: (env: RuntimeEnvironment) => RuntimeEnvironment;
|
|
56
|
+
internalRoute: (request: Request, pathname: string) => Promise<Response | null>;
|
|
57
|
+
collectPrerenderPaths: (request: Request, env: RuntimeEnvironment, ctx: ExecutionContext) => Promise<Array<string>>;
|
|
58
|
+
staticNotFound?: (request: Request, env: RuntimeEnvironment) => Promise<Response>;
|
|
59
|
+
emailReceipt?: (request: Request, env: RuntimeEnvironment, ctx: ExecutionContext) => Promise<Response>;
|
|
60
|
+
isr?: {
|
|
61
|
+
deploymentId: string;
|
|
62
|
+
handle: (request: Request, env: RuntimeEnvironment, ctx: ExecutionContext, render: (request: Request) => Promise<Response>) => Promise<Response | null>;
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
/**
|
|
66
|
+
* Answer the prerender runner. A getPrerenderPaths() error is returned in the
|
|
67
|
+
* body so the build can show which page and entry to fix, not only HTTP 500.
|
|
68
|
+
*/
|
|
69
|
+
export declare function prerenderPathsResponse(collect: () => Promise<Array<string>>): Promise<Response>;
|
|
70
|
+
export declare function createWorkerFetch(options: WorkerFetchOptions): (request: Request, env: RuntimeEnvironment, ctx: ExecutionContext) => Promise<Response>;
|
|
71
|
+
type ClientAssetTags = {
|
|
72
|
+
css: string;
|
|
73
|
+
preloads: string;
|
|
74
|
+
body: string;
|
|
75
|
+
devCss?: Array<DevCssAsset>;
|
|
76
|
+
};
|
|
77
|
+
type ManifestLoader = (request: Request, env: RuntimeEnvironment) => Promise<ClientManifest | null>;
|
|
78
|
+
export declare function createManifestLoader(): ManifestLoader;
|
|
79
|
+
type ClientAssetOptions = {
|
|
80
|
+
entryId: string;
|
|
81
|
+
entryUrl: string;
|
|
82
|
+
extraEntryId?: string;
|
|
83
|
+
extraEntryUrl?: string;
|
|
84
|
+
pageCssKeys?: Record<string, Array<string>>;
|
|
85
|
+
devRootPhases?: Record<string, Array<Array<string>>>;
|
|
86
|
+
kind: "ssr" | "pages" | "islands";
|
|
87
|
+
dev?: boolean;
|
|
88
|
+
reactRefresh?: boolean;
|
|
89
|
+
devCss?: (request: Request, env: RuntimeEnvironment, options: {
|
|
90
|
+
kind: "pages" | "islands";
|
|
91
|
+
componentId: string;
|
|
92
|
+
rootPhases: Array<Array<string>>;
|
|
93
|
+
}) => Promise<Array<DevCssAsset>>;
|
|
94
|
+
};
|
|
95
|
+
/** Frameworks supply only client entry IDs and active layout/page roots. */
|
|
96
|
+
export declare function createClientAssetTags(options: ClientAssetOptions, loadManifest?: ManifestLoader): (request: Request, env: RuntimeEnvironment, componentId?: string) => Promise<ClientAssetTags>;
|
|
21
97
|
type PageGetArguments = Parameters<typeof handlePageGet>;
|
|
22
98
|
type PageModule = {
|
|
23
99
|
loader?: PageGetArguments[0];
|
|
24
100
|
head?: PageGetArguments[1];
|
|
25
101
|
action?: Parameters<typeof handlePageMutation>[0];
|
|
26
102
|
actions?: Record<string, Parameters<typeof handlePageMutation>[0]>;
|
|
103
|
+
/** The page publishes its loader's validated query to the browser. */
|
|
104
|
+
exposeQuery?: boolean;
|
|
105
|
+
query?: StandardSchemaV1;
|
|
27
106
|
};
|
|
28
107
|
type PageRouteOptions = {
|
|
29
108
|
load?: () => Promise<PageModule>;
|
|
@@ -34,6 +113,8 @@ type PageRouteOptions = {
|
|
|
34
113
|
headConfig: PageGetArguments[6] | null;
|
|
35
114
|
renderOptions: PageGetArguments[7];
|
|
36
115
|
middlewareBoundaries?: NonNullable<PageGetArguments[7]>["boundaries"];
|
|
116
|
+
/** Loads the `.server` companion of a boundary component, by plan id. */
|
|
117
|
+
boundaryHeads?: NonNullable<NonNullable<PageGetArguments[7]>["boundaries"]>["loadHeads"];
|
|
37
118
|
namedActions?: boolean;
|
|
38
119
|
trailingSlash?: boolean;
|
|
39
120
|
catchAllParam?: string;
|
|
@@ -124,6 +205,8 @@ export type RoutingRuntime = {
|
|
|
124
205
|
applyFallback: (context: Context, rules: Array<RoutingRule>) => Promise<Response | undefined>;
|
|
125
206
|
markNoMatch: (request: Request, response: Response) => Response;
|
|
126
207
|
};
|
|
208
|
+
/** A compressed HEAD copy has no stream to carry the original response's identity. */
|
|
209
|
+
export declare function trackCompression(middleware: MiddlewareHandler): MiddlewareHandler;
|
|
127
210
|
/** One state owner per generated app: recursive dispatch shares rewrite and fallback guards. */
|
|
128
211
|
export declare function createRoutingRuntime(app: Hono$1, options?: {
|
|
129
212
|
dev?: boolean;
|
|
@@ -134,4 +217,4 @@ export declare function createRoutingRuntime(app: Hono$1, options?: {
|
|
|
134
217
|
export declare function markNoMatch(request: Request, response: Response): Response;
|
|
135
218
|
export declare function createHttpRouteHandler(load: () => Promise<Record<string, (c: CloudContext) => unknown>>, method: string): (c: Context) => Promise<Response>;
|
|
136
219
|
export declare function createModuleLoader<T>(load: () => Promise<T>, cache?: boolean): () => Promise<T>;
|
|
137
|
-
export { type Hono,
|
|
220
|
+
export { type Hono, matchedRoutes };
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { n as pagesRedirectResponse } from "../../redirect-
|
|
1
|
+
import { c as hasActionKey, d as searchWithoutActionKey, f as searchWithoutPreservedQuery, l as markActionKey, o as PRESERVED_QUERY_HEADER, s as actionKeySegment, t as decodePagePath, u as queryKey } from "../../url-DAQ1c3lh.mjs";
|
|
2
|
+
import { n as pagesRedirectResponse } from "../../redirect-DjyA_hx_.mjs";
|
|
3
3
|
import { i as authDependentRequests, n as markStaticAsset, r as SHARED_CACHE_HEADERS, t as isUnchangedStaticAsset } from "../../static-asset-marker-lxYeKvFP.mjs";
|
|
4
|
-
import { t as VoidAssetRewriteError } from "../../handler-
|
|
4
|
+
import { l as isVoidInternalPath, t as VoidAssetRewriteError } from "../../handler-2wAywJgj.mjs";
|
|
5
5
|
import { t as convertReturnValue } from "../../response-CyXsGfOy.mjs";
|
|
6
6
|
import { n as createClientAssetTags, r as createManifestLoader, t as ASSET_EXTENSIONS } from "../../assets-Br6_BeFJ.mjs";
|
|
7
|
-
import {
|
|
8
|
-
import { r as toUrlString, t as interpolateRouteParams } from "../../route-url-
|
|
7
|
+
import { a as recoverPageHttpException, c as ownsLoaderNotFoundBoundary, n as handlePageGet, r as handlePageMutation, s as handlesPageLoaderNotFound } from "../../protocol-DhMbnxzy.mjs";
|
|
8
|
+
import { r as toUrlString, t as interpolateRouteParams } from "../../route-url-CRC8yR_2.mjs";
|
|
9
9
|
import { t as renderDefaultErrorPage } from "../../error-pages-GORL6F_e.mjs";
|
|
10
10
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
11
11
|
import { compilePattern, matchPattern, matchPatternCaptures, mergeQueryIntoLocation, redirectToHttps, substituteParams } from "@void/edge";
|
|
12
|
+
import { getPath } from "hono/utils/url";
|
|
12
13
|
import { Context, Hono } from "hono";
|
|
13
14
|
import { matchedRoutes } from "hono/route";
|
|
14
15
|
// src/runtime/routing/worker.ts
|
|
@@ -144,9 +145,11 @@ function createWorkerFetch(options) {
|
|
|
144
145
|
}, options.versionMetadataBinding ? { headers: { "cache-control": "no-store" } } : void 0);
|
|
145
146
|
}
|
|
146
147
|
if (staticNotFound) return options.staticNotFound ? options.staticNotFound(request, env) : new Response(null, { status: 204 });
|
|
147
|
-
const internal = await options.internalRoute(request, env, ctx);
|
|
148
|
-
if (internal) return internal;
|
|
149
148
|
if (discovery) return prerenderPathsResponse(() => options.collectPrerenderPaths(request, env, ctx));
|
|
149
|
+
if (isVoidInternalPath(getPath(request))) {
|
|
150
|
+
const internal = await options.internalRoute(request, url.pathname);
|
|
151
|
+
if (internal) return internal;
|
|
152
|
+
}
|
|
150
153
|
if (options.alwaysUseHttps) {
|
|
151
154
|
const redirect = redirectToHttps(request);
|
|
152
155
|
if (redirect) return redirect;
|
|
@@ -162,6 +165,16 @@ function createWorkerFetch(options) {
|
|
|
162
165
|
};
|
|
163
166
|
}
|
|
164
167
|
// src/runtime/routing/pages.ts
|
|
168
|
+
/** Render options with the boundary head loaders, which the JSON-serialized options cannot carry. */
|
|
169
|
+
function withBoundaryHeads(options, boundaries = options.renderOptions?.boundaries) {
|
|
170
|
+
return {
|
|
171
|
+
...options.renderOptions,
|
|
172
|
+
...boundaries && { boundaries: options.boundaryHeads ? {
|
|
173
|
+
...boundaries,
|
|
174
|
+
loadHeads: options.boundaryHeads
|
|
175
|
+
} : boundaries }
|
|
176
|
+
};
|
|
177
|
+
}
|
|
165
178
|
function preparePageRequest(c, options) {
|
|
166
179
|
if (!options.trailingSlash) return true;
|
|
167
180
|
if (!c.req.path.endsWith("/")) return false;
|
|
@@ -198,10 +211,7 @@ function createPageErrorHandler(matchedRoutes, fallback) {
|
|
|
198
211
|
const routeIndex = c.req.routeIndex;
|
|
199
212
|
try {
|
|
200
213
|
c.req.routeIndex = endpointIndex;
|
|
201
|
-
return await recoverPageHttpException(error, c, options.render, options.assets, options.headConfig ?? void 0, {
|
|
202
|
-
...options.renderOptions,
|
|
203
|
-
boundaries: options.middlewareBoundaries ?? { errors: [] }
|
|
204
|
-
}) ?? fallback(error, c);
|
|
214
|
+
return await recoverPageHttpException(error, c, options.render, options.assets, options.headConfig ?? void 0, withBoundaryHeads(options, options.middlewareBoundaries ?? { errors: [] })) ?? fallback(error, c);
|
|
205
215
|
} catch (failure) {
|
|
206
216
|
return fallback(failure instanceof Error ? failure : new Error("Unable to render Pages error boundary", { cause: failure }), c);
|
|
207
217
|
} finally {
|
|
@@ -224,6 +234,14 @@ function createNamedActionMarker(matchedRoutes) {
|
|
|
224
234
|
await next();
|
|
225
235
|
};
|
|
226
236
|
}
|
|
237
|
+
function exposedPageQuery(mod) {
|
|
238
|
+
const query = mod.query;
|
|
239
|
+
const exposeQuery = mod.exposeQuery === true && typeof query?.["~standard"]?.validate === "function";
|
|
240
|
+
return {
|
|
241
|
+
exposeQuery,
|
|
242
|
+
querySchema: exposeQuery ? query : void 0
|
|
243
|
+
};
|
|
244
|
+
}
|
|
227
245
|
function createPageGetHandler(options) {
|
|
228
246
|
const handler = markRouteHandler(async (context) => {
|
|
229
247
|
if (!preparePageRequest(context, options)) return context.notFound();
|
|
@@ -236,9 +254,12 @@ function createPageGetHandler(options) {
|
|
|
236
254
|
} };
|
|
237
255
|
}
|
|
238
256
|
try {
|
|
239
|
-
return await handlePageGet(mod.loader, mod.head, context, options.componentId, options.render, options.assets, options.headConfig ?? void 0,
|
|
257
|
+
return await handlePageGet(mod.loader, mod.head, context, options.componentId, options.render, options.assets, options.headConfig ?? void 0, {
|
|
258
|
+
...withBoundaryHeads(options),
|
|
259
|
+
...exposedPageQuery(mod)
|
|
260
|
+
});
|
|
240
261
|
} catch (error) {
|
|
241
|
-
const response = await recoverPageHttpException(error, context, options.render, options.assets, options.headConfig ?? void 0, options
|
|
262
|
+
const response = await recoverPageHttpException(error, context, options.render, options.assets, options.headConfig ?? void 0, withBoundaryHeads(options));
|
|
242
263
|
if (response) return response;
|
|
243
264
|
throw error;
|
|
244
265
|
}
|
|
@@ -254,14 +275,14 @@ function createStaticNotFound(options) {
|
|
|
254
275
|
...options.renderOptions,
|
|
255
276
|
renderMode: "server"
|
|
256
277
|
},
|
|
257
|
-
render: (page, assets, url) => options.render({
|
|
278
|
+
render: (page, assets, url, request) => options.render({
|
|
258
279
|
...page,
|
|
259
280
|
documentOnly: true
|
|
260
281
|
}, {
|
|
261
282
|
...assets,
|
|
262
283
|
body: "",
|
|
263
284
|
preloads: ""
|
|
264
|
-
}, url)
|
|
285
|
+
}, url, request)
|
|
265
286
|
});
|
|
266
287
|
return (request, env) => handle(new Context(new Request(new URL("/404", request.url)), { env }));
|
|
267
288
|
}
|
|
@@ -276,7 +297,10 @@ function createPageMutationHandler(options) {
|
|
|
276
297
|
const handler = options.namedActions ? typeof candidate === "function" ? candidate : void 0 : mod.action;
|
|
277
298
|
if (options.namedActions && !handler) return new Response("Unknown action" + (actionName ? ": " + actionName : ""), { status: 404 });
|
|
278
299
|
if (actionName) markActionKey(context.req.raw);
|
|
279
|
-
return handlePageMutation(handler, mod.loader, mod.head, context, options.componentId, options.render, options.assets, options.headConfig ?? void 0,
|
|
300
|
+
return handlePageMutation(handler, mod.loader, mod.head, context, options.componentId, options.render, options.assets, options.headConfig ?? void 0, {
|
|
301
|
+
...withBoundaryHeads(options),
|
|
302
|
+
...exposedPageQuery(mod)
|
|
303
|
+
});
|
|
280
304
|
};
|
|
281
305
|
if (options.namedActions) namedActionHandlers.add(mutationHandler);
|
|
282
306
|
return markRouteHandler(mutationHandler);
|
|
@@ -898,6 +922,20 @@ function buildPrerenderPath(pattern, params, file, index) {
|
|
|
898
922
|
}
|
|
899
923
|
}
|
|
900
924
|
// src/runtime/routing/index.ts
|
|
925
|
+
const compressionCopyTrackers = /* @__PURE__ */ new WeakMap();
|
|
926
|
+
/** A compressed HEAD copy has no stream to carry the original response's identity. */
|
|
927
|
+
function trackCompression(middleware) {
|
|
928
|
+
return async (c, next) => {
|
|
929
|
+
if (c.req.method !== "HEAD") return middleware(c, next);
|
|
930
|
+
let source;
|
|
931
|
+
const result = await middleware(c, async () => {
|
|
932
|
+
await next();
|
|
933
|
+
if (compressionCopyTrackers.has(c)) source = c.res;
|
|
934
|
+
});
|
|
935
|
+
if (source && c.res !== source) compressionCopyTrackers.get(c)?.(source, c.res);
|
|
936
|
+
return result;
|
|
937
|
+
};
|
|
938
|
+
}
|
|
901
939
|
/** One state owner per generated app: recursive dispatch shares rewrite and fallback guards. */
|
|
902
940
|
function createRoutingRuntime(app, options = {}) {
|
|
903
941
|
const originalUrls = /* @__PURE__ */ new WeakMap();
|
|
@@ -955,10 +993,11 @@ function createRoutingRuntime(app, options = {}) {
|
|
|
955
993
|
}
|
|
956
994
|
};
|
|
957
995
|
const isRouteMiss = (c, response) => routeMisses.get(c)?.some((miss) => miss === response || miss.body !== null && miss.body === response.body) === true || response.body !== null && missBodies.get(c)?.has(response.body) === true;
|
|
958
|
-
const tracksResponseCopies = /* @__PURE__ */ new WeakSet();
|
|
959
996
|
const trackResponseCopies = (c) => {
|
|
960
|
-
if (
|
|
961
|
-
|
|
997
|
+
if (compressionCopyTrackers.has(c)) return;
|
|
998
|
+
compressionCopyTrackers.set(c, (source, copy) => {
|
|
999
|
+
if (isRouteMiss(c, source)) recordMiss(c, copy);
|
|
1000
|
+
});
|
|
962
1001
|
const descriptor = Object.getOwnPropertyDescriptor(Object.getPrototypeOf(c), "res");
|
|
963
1002
|
if (descriptor?.get && descriptor.set) {
|
|
964
1003
|
const set = descriptor.set;
|
|
@@ -1215,4 +1254,4 @@ function createModuleLoader(load, cache = true) {
|
|
|
1215
1254
|
return module;
|
|
1216
1255
|
};
|
|
1217
1256
|
}
|
|
1218
|
-
export { Hono, buildPrerenderPath, createAssetFallback, createAssetNotFound, createClientAssetTags, createErrorRenderer, createHttpRouteHandler, createManifestLoader, createModuleLoader, createNamedActionMarker, createPageErrorHandler, createPageGetHandler, createPageMutationHandler, createPagesFallback, createRoutingRuntime, createSsrFallback, createStaticNotFound, createWorkerFetch, filterInternalBindings, markNoMatch, markRouteHandler, matchedRoutes, prerenderPathsResponse };
|
|
1257
|
+
export { Hono, buildPrerenderPath, createAssetFallback, createAssetNotFound, createClientAssetTags, createErrorRenderer, createHttpRouteHandler, createManifestLoader, createModuleLoader, createNamedActionMarker, createPageErrorHandler, createPageGetHandler, createPageMutationHandler, createPagesFallback, createRoutingRuntime, createSsrFallback, createStaticNotFound, createWorkerFetch, filterInternalBindings, markNoMatch, markRouteHandler, matchedRoutes, prerenderPathsResponse, trackCompression };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as RoutePath, c as RouteUrl, d as
|
|
2
|
-
export { Href, RequestUrl, RouteDestination, RouteOptions, RoutePath, RouteQuery, RouteQueryValue, RouteUrl, RouteUrlInput, TypedRoutes, interpolateRouteParams, routeUrl, toUrlString };
|
|
1
|
+
import { a as RoutePath, c as RouteUrl, d as TypedRoutes, f as interpolateRouteParams, i as RouteOptions, l as RouteUrlArgs, m as toUrlString, n as RequestUrl, o as RouteQuery, p as routeUrl, r as RouteDestination, s as RouteQueryValue, t as Href, u as RouteUrlInput } from "../../route-url-zDfC-7DD.mjs";
|
|
2
|
+
export { Href, RequestUrl, RouteDestination, RouteOptions, RoutePath, RouteQuery, RouteQueryValue, RouteUrl, RouteUrlArgs, RouteUrlInput, TypedRoutes, interpolateRouteParams, routeUrl, toUrlString };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as interpolateRouteParams, n as routeUrl, r as toUrlString } from "../../route-url-
|
|
1
|
+
export { t as interpolateRouteParams, n as routeUrl, r as toUrlString } from "../../route-url-CRC8yR_2.mjs";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { a as getRawRuntimeEnv } from "../../raw-5rak34QN.mjs";
|
|
2
2
|
import { a as requireRuntimeBinding } from "../../runtime-C_VPIJBF.mjs";
|
|
3
|
-
import { t as UsageLimit } from "../../limits-
|
|
3
|
+
import { t as UsageLimit } from "../../limits-3I3VdX2E.mjs";
|
|
4
4
|
import { i as validateSandboxOptions, n as SANDBOX_PORT_HEADER, r as SandboxContainer } from "../../container-CR_tqFtd.mjs";
|
|
5
5
|
export * from "@cloudflare/sandbox";
|
|
6
6
|
// src/runtime/sandbox/index.ts
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { t as RuntimeEnv } from "../../raw-CtfNvKyY.mjs";
|
|
2
|
+
import { a as WorkflowClass } from "../../index-Cvqotnhc.mjs";
|
|
3
|
+
/** Create the class exported by the generated Worker for either Workflow definition form. */
|
|
4
|
+
export declare function createWorkflowEntrypoint(Workflow: WorkflowClass<unknown, RuntimeEnv>, options: {
|
|
5
|
+
isrDeploymentId?: string;
|
|
6
|
+
validateEnv?: (env: RuntimeEnv) => Promise<void>;
|
|
7
|
+
remoteEnv?: (env: RuntimeEnv) => RuntimeEnv;
|
|
8
|
+
}): WorkflowClass<unknown, RuntimeEnv>;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { o as withRuntimeEnv } from "../../runtime-C_VPIJBF.mjs";
|
|
2
|
+
// src/runtime/workflows/entry.ts
|
|
3
|
+
function scopedStep(step, env) {
|
|
4
|
+
function scoped(callback) {
|
|
5
|
+
return typeof callback === "function" ? (input) => withRuntimeEnv(env, () => callback(input)) : callback;
|
|
6
|
+
}
|
|
7
|
+
function scopedConfig(config) {
|
|
8
|
+
const retries = config?.retries;
|
|
9
|
+
return typeof retries?.delay === "function" ? {
|
|
10
|
+
...config,
|
|
11
|
+
retries: {
|
|
12
|
+
...retries,
|
|
13
|
+
delay: scoped(retries.delay)
|
|
14
|
+
}
|
|
15
|
+
} : config;
|
|
16
|
+
}
|
|
17
|
+
function scopedRollback(options) {
|
|
18
|
+
return typeof options?.rollback === "function" ? {
|
|
19
|
+
...options,
|
|
20
|
+
rollback: scoped(options.rollback),
|
|
21
|
+
...options.rollbackConfig && { rollbackConfig: scopedConfig(options.rollbackConfig) }
|
|
22
|
+
} : options;
|
|
23
|
+
}
|
|
24
|
+
function runStep(name, configOrCallback, callbackOrRollback, rollback) {
|
|
25
|
+
if (typeof configOrCallback === "function") return step.do(name, scoped(configOrCallback), scopedRollback(callbackOrRollback));
|
|
26
|
+
return step.do(name, scopedConfig(configOrCallback), scoped(callbackOrRollback), scopedRollback(rollback));
|
|
27
|
+
}
|
|
28
|
+
return {
|
|
29
|
+
do: runStep,
|
|
30
|
+
sleep: (name, duration) => step.sleep(name, duration),
|
|
31
|
+
sleepUntil: (name, timestamp) => step.sleepUntil(name, timestamp),
|
|
32
|
+
waitForEvent: (name, options) => step.waitForEvent(name, options)
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
/** Create the class exported by the generated Worker for either Workflow definition form. */
|
|
36
|
+
function createWorkflowEntrypoint(Workflow, options) {
|
|
37
|
+
return class extends Workflow {
|
|
38
|
+
constructor(ctx, env) {
|
|
39
|
+
super(ctx, env.__VOID_REMOTE === "1" && options.remoteEnv ? options.remoteEnv(env) : env);
|
|
40
|
+
}
|
|
41
|
+
async run(event, step) {
|
|
42
|
+
const env = this.env;
|
|
43
|
+
if (options.isrDeploymentId !== void 0) env.__VOID_ISR_DEPLOYMENT_ID ??= options.isrDeploymentId;
|
|
44
|
+
if (options.validateEnv) await options.validateEnv(env);
|
|
45
|
+
return withRuntimeEnv(env, () => super.run(event, scopedStep(step, env)));
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
export { createWorkflowEntrypoint };
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
/// <reference types="@cloudflare/workers-types" />
|
|
2
|
+
import { a as WorkflowClass, c as WorkflowEvent, d as WorkflowStep, f as defineWorkflow, i as WorkflowBinding, l as WorkflowParamsError, n as WorkflowApi, o as WorkflowContext, p as defineWorkflowEntrypoint, r as WorkflowBatchOptions, s as WorkflowCreateOptions, t as NativeWorkflowParams, u as WorkflowRun } from "../../index-Cvqotnhc.mjs";
|
|
3
|
+
export { NativeWorkflowParams, WorkflowApi, WorkflowBatchOptions, WorkflowBinding, WorkflowClass, WorkflowContext, WorkflowCreateOptions, type WorkflowEvent, WorkflowParamsError, WorkflowRun, type WorkflowStep, defineWorkflow, defineWorkflowEntrypoint };
|