@farm.js/core 0.1.39 → 0.1.41
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/dist/{agent-mcp-HcTYQmNX.d.ts → agent-mcp-BOqIxJLI.d.mts} +8 -2
- package/dist/{agent-mcp-BhneNPb4.d.mts → agent-mcp-D0eZKfci.d.ts} +8 -2
- package/dist/{agent-mcp-handler-OLRMZONF.mjs → agent-mcp-handler-HVV5LNXF.mjs} +6 -6
- package/dist/{agent-mcp-handler-MRGP3WJ3.cjs → agent-mcp-handler-YKG7KVCY.cjs} +7 -7
- package/dist/agent-runtime.cjs +10 -6
- package/dist/agent-runtime.d.mts +6 -8
- package/dist/agent-runtime.d.ts +6 -8
- package/dist/agent-runtime.mjs +9 -5
- package/dist/api/client.cjs +3 -3
- package/dist/api/client.d.mts +3 -3
- package/dist/api/client.d.ts +3 -3
- package/dist/api/client.mjs +2 -2
- package/dist/api/route-manager.cjs +15 -13
- package/dist/api/route-manager.d.mts +8 -10
- package/dist/api/route-manager.d.ts +8 -10
- package/dist/api/route-manager.mjs +14 -12
- package/dist/api/runtime.cjs +12 -10
- package/dist/api/runtime.d.mts +7 -9
- package/dist/api/runtime.d.ts +7 -9
- package/dist/api/runtime.mjs +11 -9
- package/dist/{api-client-CyFtZFJ4.d.ts → api-client-BJv9mTbO.d.ts} +2 -2
- package/dist/{api-client-BjMmY8OD.d.mts → api-client-Dk9QOLwr.d.mts} +2 -2
- package/dist/api.cjs +17 -15
- package/dist/api.d.mts +10 -12
- package/dist/api.d.ts +10 -12
- package/dist/api.mjs +16 -14
- package/dist/{app-DVzmmbNO.d.mts → app-CzTSMJaf.d.mts} +12 -5
- package/dist/{app-CMkoghtp.d.ts → app-DM8e1z3G.d.ts} +12 -5
- package/dist/app-markdown.cjs +7 -6
- package/dist/app-markdown.d.mts +7 -9
- package/dist/app-markdown.d.ts +7 -9
- package/dist/app-markdown.mjs +6 -5
- package/dist/cache.cjs +6 -3
- package/dist/cache.d.mts +23 -2
- package/dist/cache.d.ts +23 -2
- package/dist/cache.mjs +5 -2
- package/dist/{chunk-EGCTIS5F.mjs → chunk-24SP5TGU.mjs} +1 -1
- package/dist/{chunk-2ZYGC6SS.cjs → chunk-25LPIZSX.cjs} +3 -3
- package/dist/{chunk-ARC7I3O2.mjs → chunk-26RUNDIR.mjs} +1 -1
- package/dist/{chunk-472NCAZ7.cjs → chunk-2FUIT2G2.cjs} +3 -3
- package/dist/{chunk-YFYUYWL7.cjs → chunk-32TZ3QTP.cjs} +723 -454
- package/dist/{chunk-CQMVIOYP.mjs → chunk-35WS7P2V.mjs} +29 -131
- package/dist/{chunk-QTXBII4Z.cjs → chunk-3TB5QGUW.cjs} +5 -5
- package/dist/chunk-45QJHGZM.cjs +1063 -0
- package/dist/{chunk-677THUVP.mjs → chunk-4C7KTKX7.mjs} +1 -1
- package/dist/{chunk-FUZEBRP3.mjs → chunk-4GP3XZ4Z.mjs} +5 -3
- package/dist/{chunk-KTSUBU2E.mjs → chunk-4KQDHTWX.mjs} +2 -2
- package/dist/chunk-4TLUFAIP.cjs +92 -0
- package/dist/chunk-4U5XZDLG.cjs +80 -0
- package/dist/{chunk-P664ZVTV.mjs → chunk-4ZZNPK25.mjs} +2 -2
- package/dist/{chunk-KIIMAWOJ.cjs → chunk-5NAVKJCZ.cjs} +35 -105
- package/dist/{chunk-LSKZMJMP.cjs → chunk-64SBBZDU.cjs} +38 -1
- package/dist/chunk-6BWKJ6QS.cjs +43 -0
- package/dist/{chunk-JSROZYYO.cjs → chunk-6D24SDKO.cjs} +1 -20
- package/dist/chunk-6IZWX6ES.cjs +74 -0
- package/dist/{chunk-QRKIMN7T.mjs → chunk-6LVRDOAW.mjs} +32 -6
- package/dist/{chunk-YWN746US.cjs → chunk-6MVFHNYZ.cjs} +85 -54
- package/dist/{chunk-VWBHM3F6.mjs → chunk-6PKXK4TY.mjs} +3 -3
- package/dist/chunk-6QOLZITB.cjs +22 -0
- package/dist/{chunk-OAHTRMIC.mjs → chunk-724JLMS4.mjs} +11 -11
- package/dist/chunk-7GNWGLWB.mjs +14 -0
- package/dist/{chunk-34UCJRQO.cjs → chunk-7RNAKBWF.cjs} +2 -2
- package/dist/{chunk-U6QLDL3G.mjs → chunk-7UEEHAW7.mjs} +1 -1
- package/dist/{chunk-UPJLHLJU.cjs → chunk-ALPWLT27.cjs} +4 -4
- package/dist/{chunk-ATSDUUFK.mjs → chunk-AX7S67YV.mjs} +33 -40
- package/dist/{chunk-MSSFIQGM.mjs → chunk-B2GSRB3P.mjs} +41 -10
- package/dist/chunk-BGGWKZ2V.mjs +6096 -0
- package/dist/{chunk-H5CLOUZS.cjs → chunk-BMOBTMDR.cjs} +5 -5
- package/dist/{chunk-Q2KB32T4.mjs → chunk-BPNRQ5BA.mjs} +6 -6
- package/dist/{chunk-E2ROOWQC.cjs → chunk-BPOTSHDO.cjs} +24 -87
- package/dist/chunk-BRYPZIMB.mjs +6 -0
- package/dist/{chunk-WFRT7JPX.mjs → chunk-BYQVROIP.mjs} +2 -2
- package/dist/{chunk-HALDNTIV.mjs → chunk-BYR3RQPB.mjs} +10 -73
- package/dist/{chunk-5PWXMJOH.cjs → chunk-C5KVWHIH.cjs} +36 -36
- package/dist/chunk-CALY6QG6.mjs +963 -0
- package/dist/{chunk-WC5UV2HQ.cjs → chunk-CBXBGM72.cjs} +2 -2
- package/dist/{chunk-WW46B6HA.cjs → chunk-CGR525MJ.cjs} +84 -45
- package/dist/{chunk-6V4TDWEC.cjs → chunk-CGVPXIRN.cjs} +18 -1
- package/dist/chunk-COABSY3U.mjs +196 -0
- package/dist/chunk-CZS6OACQ.mjs +63 -0
- package/dist/{chunk-SGBJ247Q.cjs → chunk-D4ROBNTK.cjs} +2 -2
- package/dist/{chunk-WEW2JVA4.cjs → chunk-D5IHNDHI.cjs} +6 -6
- package/dist/{chunk-QG775BRV.cjs → chunk-D64OPY6A.cjs} +72 -54
- package/dist/{chunk-QUCXCDE2.cjs → chunk-EH3464KF.cjs} +1 -1
- package/dist/{chunk-75HN5IZ3.mjs → chunk-ENOBPDKZ.mjs} +21 -19
- package/dist/{chunk-HD5CF3OE.mjs → chunk-ETPEZLS3.mjs} +2 -2
- package/dist/{chunk-HRETEZ2Z.cjs → chunk-EX4MKHXN.cjs} +37 -35
- package/dist/{chunk-TO4GJ56K.cjs → chunk-FEYQCYT7.cjs} +58 -18
- package/dist/chunk-FGH3ZXTP.mjs +1063 -0
- package/dist/{chunk-CUM5NYL5.mjs → chunk-FIAPD365.mjs} +1 -1
- package/dist/{chunk-HYTZYOW2.mjs → chunk-FJGIVDA5.mjs} +1197 -7906
- package/dist/chunk-FVPXT2JR.cjs +63 -0
- package/dist/{chunk-MYIZXDZA.mjs → chunk-FWCGUVVL.mjs} +1 -1
- package/dist/{chunk-D2ULAULS.cjs → chunk-FXFKIJDA.cjs} +9 -7
- package/dist/{chunk-RW63BOV7.cjs → chunk-GB7LDGY5.cjs} +2 -2
- package/dist/chunk-GC3EM6H4.mjs +80 -0
- package/dist/{chunk-E3UK5IIB.cjs → chunk-GS3WR5HX.cjs} +5 -3
- package/dist/{chunk-QFW2IH5E.mjs → chunk-GZTUT75U.mjs} +5 -2
- package/dist/chunk-H3EGVQE5.mjs +22 -0
- package/dist/chunk-HANGSYMB.mjs +67 -0
- package/dist/{chunk-RSOJ7DRT.mjs → chunk-HCSVR4YZ.mjs} +1 -58
- package/dist/{chunk-QYMZOOC5.mjs → chunk-HJ64F4GS.mjs} +12 -44
- package/dist/{chunk-P3PLW4FR.mjs → chunk-HKFBMHCD.mjs} +4 -4
- package/dist/{chunk-BXDJXFQG.cjs → chunk-I5MG3TKE.cjs} +4 -4
- package/dist/{chunk-VNGH5MLF.mjs → chunk-I6UVKUYK.mjs} +1 -1
- package/dist/{chunk-EPYU2EBL.mjs → chunk-IF4NU2NG.mjs} +1 -1
- package/dist/{chunk-WXJLNP33.cjs → chunk-IFWSR7YZ.cjs} +9 -7
- package/dist/{chunk-IVLZZZEI.mjs → chunk-IM7DY3ED.mjs} +1 -1
- package/dist/{chunk-W36M2BQ4.mjs → chunk-IN6RCKLL.mjs} +6 -5
- package/dist/{chunk-F5QO4FNE.mjs → chunk-INQ64HTJ.mjs} +43 -11
- package/dist/{chunk-SDOTRX3V.cjs → chunk-JEIG3EWE.cjs} +8 -8
- package/dist/{chunk-UWPLULNK.mjs → chunk-JGHCKIRI.mjs} +84 -24
- package/dist/{chunk-BFJTHYTN.mjs → chunk-JIYYX7WU.mjs} +10 -8
- package/dist/{chunk-CIOT4HGT.cjs → chunk-JOTUZIM4.cjs} +14 -14
- package/dist/{chunk-SKVTP5PR.mjs → chunk-JOW4HDJO.mjs} +1 -62
- package/dist/{chunk-6MVFL3R5.cjs → chunk-JR4QCLJY.cjs} +1 -58
- package/dist/{chunk-CGBDNNSM.cjs → chunk-KEXK442I.cjs} +44 -12
- package/dist/{chunk-FUCSUGDM.cjs → chunk-KF6VDJH7.cjs} +3 -3
- package/dist/{chunk-EA5K5BKU.mjs → chunk-KNHBTJP6.mjs} +18 -1
- package/dist/{chunk-MVL2RAJW.mjs → chunk-KYN5ODF6.mjs} +1 -1
- package/dist/{chunk-LMPAPBUA.cjs → chunk-L6A26QT5.cjs} +36 -68
- package/dist/{chunk-RVXFINNS.cjs → chunk-L6HYACBE.cjs} +31 -31
- package/dist/chunk-LFHCG2DU.mjs +43 -0
- package/dist/{chunk-5OKBARDN.cjs → chunk-LIZTLA5F.cjs} +12 -11
- package/dist/{chunk-HXRYZWTA.mjs → chunk-LLUA2LSC.mjs} +3 -3
- package/dist/{chunk-B5J2YVG7.cjs → chunk-LYIZHJTK.cjs} +2 -2
- package/dist/{chunk-3UEVPCGW.mjs → chunk-MEASUNVY.mjs} +6 -1
- package/dist/{chunk-FZ6YYU2W.mjs → chunk-MGMF4VP7.mjs} +38 -1
- package/dist/{chunk-CNNOLE4O.mjs → chunk-MHHCLYXU.mjs} +1 -1
- package/dist/{chunk-HRSAQ23K.cjs → chunk-MHN4UR5U.cjs} +4 -4
- package/dist/{chunk-3LOLJTFV.cjs → chunk-MN4TQJ3W.cjs} +11 -11
- package/dist/{chunk-PGZDEPTM.cjs → chunk-MY5PZYAD.cjs} +10 -10
- package/dist/{chunk-ZXH4TS3F.cjs → chunk-NBPNUQYO.cjs} +3 -64
- package/dist/{chunk-VXEEATVD.cjs → chunk-NFG4PUPI.cjs} +2 -2
- package/dist/{chunk-INL3THCU.mjs → chunk-O7USYJ4U.mjs} +1 -1
- package/dist/{chunk-4ZFL5GFN.cjs → chunk-OILHPMFX.cjs} +86 -26
- package/dist/{chunk-AJQTP4OO.mjs → chunk-OJ7JP7RJ.mjs} +1 -1
- package/dist/chunk-OQ4YXWH4.cjs +6097 -0
- package/dist/{chunk-DMEPTZTI.mjs → chunk-P2UJF4SS.mjs} +47 -7
- package/dist/{chunk-T5OJPTVN.cjs → chunk-P4TYB4SF.cjs} +2 -2
- package/dist/chunk-P7XDC7UJ.mjs +92 -0
- package/dist/{chunk-SHLXACIO.cjs → chunk-PJ42JESY.cjs} +1 -9
- package/dist/{chunk-5ULKUBIA.cjs → chunk-PN676AZF.cjs} +6 -6
- package/dist/{chunk-YKZRDB5Z.mjs → chunk-PYHPXPSW.mjs} +2 -2
- package/dist/{chunk-KMTGADN3.mjs → chunk-QCVIRVHE.mjs} +1 -9
- package/dist/{chunk-5D2JIPLH.cjs → chunk-QEILRWVV.cjs} +36 -138
- package/dist/{chunk-XKG2BLFN.cjs → chunk-QIBP5EFA.cjs} +18 -35
- package/dist/{chunk-ZUPXLIGB.mjs → chunk-R65GCA6A.mjs} +647 -378
- package/dist/{chunk-BWIQR4DH.cjs → chunk-RHGK2JEN.cjs} +56 -63
- package/dist/{chunk-AS2VPMEE.cjs → chunk-ROQ4C4LJ.cjs} +1465 -8174
- package/dist/{chunk-QV4VE2OW.mjs → chunk-S6ENKNNG.mjs} +5 -3
- package/dist/{chunk-RWFLWR5J.cjs → chunk-S7MTDRYA.cjs} +17 -15
- package/dist/{chunk-PVZE2JGJ.mjs → chunk-SGB4IW7K.mjs} +43 -25
- package/dist/{chunk-GKBWWRBG.mjs → chunk-SVPGWJZF.mjs} +12 -12
- package/dist/{chunk-EKN7NSZO.cjs → chunk-SZLNU3GJ.cjs} +8 -5
- package/dist/chunk-TI7UANHI.cjs +77 -0
- package/dist/{chunk-6BK3K2GB.mjs → chunk-UIDWEU7M.mjs} +83 -44
- package/dist/{chunk-MLY2RP5R.mjs → chunk-ULQOP5UI.mjs} +6 -2
- package/dist/chunk-UNJZGVPU.cjs +6 -0
- package/dist/{chunk-5BWWFHR2.mjs → chunk-UQUEANTY.mjs} +3 -3
- package/dist/chunk-VDRM36QB.cjs +963 -0
- package/dist/chunk-VHRS3MCW.cjs +196 -0
- package/dist/{chunk-SOP2EAA6.mjs → chunk-VLPII2JJ.mjs} +1 -1
- package/dist/{chunk-RG4A6LB2.cjs → chunk-VNPXKF3G.cjs} +7 -7
- package/dist/chunk-VQDBNVOO.cjs +14 -0
- package/dist/chunk-VQGKD7RV.mjs +25 -0
- package/dist/{chunk-6HB6V3R7.mjs → chunk-VTBXE6QG.mjs} +10 -27
- package/dist/{chunk-ZMSZZXOR.mjs → chunk-WDMIW6Q6.mjs} +0 -19
- package/dist/{chunk-NBBEQLOK.cjs → chunk-WLHA5USH.cjs} +9 -9
- package/dist/{chunk-BZHXGVMA.mjs → chunk-WMBRZI5V.mjs} +5 -3
- package/dist/{chunk-4WVJLURN.mjs → chunk-WMHG64DA.mjs} +1 -1
- package/dist/{chunk-JCYYXBAJ.cjs → chunk-WROEFVNO.cjs} +3 -3
- package/dist/{chunk-A657YSP4.cjs → chunk-WSOBCAYO.cjs} +37 -35
- package/dist/{chunk-IWZKTWHZ.cjs → chunk-WU7ZS3EM.cjs} +7 -2
- package/dist/{chunk-J63ZH5OQ.cjs → chunk-X3GMHKO3.cjs} +2 -2
- package/dist/{chunk-POSPE3IO.mjs → chunk-X3NGFVRF.mjs} +61 -21
- package/dist/{chunk-VT4WFRHA.mjs → chunk-XUC6CFLE.mjs} +1 -1
- package/dist/chunk-Y5RG6B7S.mjs +77 -0
- package/dist/{chunk-EIPC3FDA.cjs → chunk-YWCYV7QC.cjs} +9 -5
- package/dist/{chunk-WLL43JMO.mjs → chunk-YYQVGKO5.mjs} +7 -5
- package/dist/chunk-YZAKIXRL.cjs +67 -0
- package/dist/chunk-ZQRCSUSB.cjs +25 -0
- package/dist/{chunk-6XWDE2P2.cjs → chunk-ZTP3BJG6.cjs} +64 -24
- package/dist/{chunk-ZMMBIVQM.mjs → chunk-ZZGQD7A4.mjs} +16 -86
- package/dist/{client-plugins-CsCuCLBz.d.mts → client-plugins-CkYwvDJ0.d.mts} +2545 -2665
- package/dist/{client-plugins-D0ke-Hc8.d.ts → client-plugins-DfeKd0sD.d.ts} +2545 -2665
- package/dist/client-plugins.d.mts +6 -8
- package/dist/client-plugins.d.ts +6 -8
- package/dist/client.cjs +5 -5
- package/dist/client.d.mts +12 -13
- package/dist/client.d.ts +12 -13
- package/dist/client.mjs +4 -4
- package/dist/client.react-server.mjs +2 -0
- package/dist/config.d.mts +6 -8
- package/dist/config.d.ts +6 -8
- package/dist/{devtools-LW4QQ5J3.cjs → devtools-2YHAJYH6.cjs} +21 -18
- package/dist/{devtools-5AFIPVUJ.mjs → devtools-N3QLRIQU.mjs} +20 -17
- package/dist/docs.cjs +23 -20
- package/dist/docs.d.mts +7 -9
- package/dist/docs.d.ts +7 -9
- package/dist/docs.mjs +22 -19
- package/dist/{endpoint-CA-TNX60.d.ts → endpoint-BOE0IAaG.d.ts} +6 -3
- package/dist/{endpoint-CCHFqyTE.d.mts → endpoint-DGZRZHux.d.mts} +6 -3
- package/dist/environment/vite.cjs +6 -2
- package/dist/environment/vite.d.mts +11 -2
- package/dist/environment/vite.d.ts +11 -2
- package/dist/environment/vite.mjs +5 -1
- package/dist/headers.cjs +4 -4
- package/dist/headers.mjs +3 -3
- package/dist/image/server.cjs +7 -3
- package/dist/image/server.d.mts +10 -2
- package/dist/image/server.d.ts +10 -2
- package/dist/image/server.mjs +6 -2
- package/dist/image/sharp.cjs +12 -10
- package/dist/image/sharp.d.mts +1 -1
- package/dist/image/sharp.d.ts +1 -1
- package/dist/image/sharp.mjs +4 -2
- package/dist/{image-config-Duob7wER.d.ts → image-config-BpH1q5R8.d.mts} +4 -1
- package/dist/{image-config-Duob7wER.d.mts → image-config-BpH1q5R8.d.ts} +4 -1
- package/dist/image.d.mts +1 -1
- package/dist/image.d.ts +1 -1
- package/dist/index.cjs +90 -68
- package/dist/index.d.mts +28 -145
- package/dist/index.d.ts +28 -145
- package/dist/index.mjs +103 -81
- package/dist/{integration-api-BPJo5oXb.d.ts → integration-api-BuPHMeKz.d.ts} +2 -2
- package/dist/{integration-api-0y4FXJpC.d.mts → integration-api-DWyMmvrR.d.mts} +2 -2
- package/dist/integration-orm-P2II2EBK.cjs +14 -0
- package/dist/{integration-orm-KV5B3BGZ.mjs → integration-orm-RBKCIQYZ.mjs} +4 -3
- package/dist/integrations.cjs +7 -5
- package/dist/integrations.d.mts +8 -10
- package/dist/integrations.d.ts +8 -10
- package/dist/integrations.mjs +6 -4
- package/dist/internal/app-markdown-runtime.cjs +6 -5
- package/dist/internal/app-markdown-runtime.d.mts +7 -9
- package/dist/internal/app-markdown-runtime.d.ts +7 -9
- package/dist/internal/app-markdown-runtime.mjs +5 -4
- package/dist/internal/build-runtime.cjs +57 -56
- package/dist/internal/build-runtime.d.mts +8 -10
- package/dist/internal/build-runtime.d.ts +8 -10
- package/dist/internal/build-runtime.mjs +56 -55
- package/dist/internal/cli-runtime.cjs +37 -31
- package/dist/internal/cli-runtime.mjs +37 -31
- package/dist/internal/client-error-overlay.cjs +4 -4
- package/dist/internal/client-error-overlay.mjs +1 -1
- package/dist/internal/compression-runtime.d.mts +6 -8
- package/dist/internal/compression-runtime.d.ts +6 -8
- package/dist/internal/config-runtime.cjs +21 -18
- package/dist/internal/config-runtime.d.mts +7 -9
- package/dist/internal/config-runtime.d.ts +7 -9
- package/dist/internal/config-runtime.mjs +20 -17
- package/dist/internal/docs-precompiled-runtime.cjs +3 -3
- package/dist/internal/docs-precompiled-runtime.mjs +2 -2
- package/dist/internal/infra-analytics-runtime.cjs +7 -7
- package/dist/internal/infra-analytics-runtime.mjs +5 -5
- package/dist/internal/metadata-image-runtime.cjs +4 -3
- package/dist/internal/metadata-image-runtime.mjs +3 -2
- package/dist/internal/product-telemetry-runtime.cjs +2 -2
- package/dist/internal/product-telemetry-runtime.mjs +1 -1
- package/dist/internal/production-node-env.cjs +2 -2
- package/dist/internal/production-node-env.mjs +1 -1
- package/dist/internal/production-runtime.cjs +53 -28
- package/dist/internal/production-runtime.d.mts +46 -15
- package/dist/internal/production-runtime.d.ts +46 -15
- package/dist/internal/production-runtime.mjs +57 -32
- package/dist/layers-CM5i6T7z.d.mts +55 -0
- package/dist/layers-CM5i6T7z.d.ts +55 -0
- package/dist/markdown.cjs +4 -4
- package/dist/markdown.d.mts +6 -8
- package/dist/markdown.d.ts +6 -8
- package/dist/markdown.mjs +3 -3
- package/dist/middleware.cjs +16 -10
- package/dist/middleware.d.mts +8 -10
- package/dist/middleware.d.ts +8 -10
- package/dist/middleware.mjs +19 -13
- package/dist/navigation.cjs +4 -4
- package/dist/navigation.d.mts +9 -10
- package/dist/navigation.d.ts +9 -10
- package/dist/navigation.mjs +3 -3
- package/dist/{nitro-MPZJGPXK.mjs → nitro-KDACKNHU.mjs} +3 -2
- package/dist/{nitro-7F65EZZS.cjs → nitro-NPGU6VBT.cjs} +4 -3
- package/dist/observability.cjs +2 -2
- package/dist/observability.mjs +1 -1
- package/dist/plugin-DBBZ4JI2.cjs +32 -0
- package/dist/plugin-SYMK7PQ2.mjs +32 -0
- package/dist/plugin.cjs +56 -43
- package/dist/plugin.d.mts +25 -8
- package/dist/plugin.d.ts +25 -8
- package/dist/plugin.mjs +57 -44
- package/dist/{production-runtime-DfRP0cV0.d.mts → production-runtime-BTkXQdYy.d.mts} +17 -3
- package/dist/{production-runtime-BaI3WHnV.d.ts → production-runtime-DFC7pgbp.d.ts} +17 -3
- package/dist/query/client.cjs +2 -2
- package/dist/query/client.mjs +3 -3
- package/dist/{render-plan-Dg8RBYFa.d.mts → render-plan-5rFeWmk7.d.mts} +1 -1
- package/dist/{render-plan-CfIdJKAf.d.ts → render-plan-BoAK9xFC.d.ts} +1 -1
- package/dist/renderer-client.d.mts +8 -9
- package/dist/renderer-client.d.ts +8 -9
- package/dist/{request-DfE02G_A.d.mts → request-BxBWigtl.d.mts} +1 -1
- package/dist/{request-CEbHIIl4.d.ts → request-fciwmd3n.d.ts} +1 -1
- package/dist/request.cjs +3 -3
- package/dist/request.d.mts +7 -9
- package/dist/request.d.ts +7 -9
- package/dist/request.mjs +2 -2
- package/dist/{route-rendering-C4oHbv6C.d.ts → route-rendering-BCM1QzEf.d.mts} +1 -1
- package/dist/{route-rendering-BHyOfXjD.d.mts → route-rendering-BLZT0IP0.d.ts} +1 -1
- package/dist/{router-uRN_29Em.d.ts → router-CkheNX3-.d.ts} +1 -1
- package/dist/{router-DwhA61SB.d.mts → router-DyZJWc1_.d.mts} +1 -1
- package/dist/routes.cjs +6 -5
- package/dist/routes.d.mts +6 -8
- package/dist/routes.d.ts +6 -8
- package/dist/routes.mjs +5 -4
- package/dist/{runtime-COk03hmx.d.ts → runtime-DfU4sKa5.d.ts} +3 -3
- package/dist/{runtime-BEdHhN4C.d.mts → runtime-wexvUN5J.d.mts} +3 -3
- package/dist/{schema-dev-notice-Y7MQEFGN.cjs → schema-dev-notice-5JPE67AI.cjs} +6 -4
- package/dist/{schema-dev-notice-O67CPXJ6.mjs → schema-dev-notice-WLPZ6WKU.mjs} +4 -2
- package/dist/server-action-security.cjs +4 -3
- package/dist/server-action-security.mjs +3 -2
- package/dist/server-client-bridge-DKWDl5NB.d.mts +7 -0
- package/dist/server-client-bridge-DKWDl5NB.d.ts +7 -0
- package/dist/server-fn-client.d.mts +3 -3
- package/dist/server-fn-client.d.ts +3 -3
- package/dist/server-fn.cjs +8 -7
- package/dist/server-fn.d.mts +1 -1
- package/dist/server-fn.d.ts +1 -1
- package/dist/server-fn.mjs +7 -6
- package/dist/server-plugins.cjs +5 -5
- package/dist/server-plugins.d.mts +7 -9
- package/dist/server-plugins.d.ts +7 -9
- package/dist/server-plugins.mjs +4 -4
- package/dist/server-query-client.d.mts +1 -1
- package/dist/server-query-client.d.ts +1 -1
- package/dist/server-query.cjs +9 -8
- package/dist/server-query.d.mts +1 -1
- package/dist/server-query.d.ts +1 -1
- package/dist/server-query.mjs +8 -7
- package/dist/server.cjs +97 -73
- package/dist/server.d.mts +18 -13
- package/dist/server.d.ts +18 -13
- package/dist/server.mjs +82 -58
- package/dist/{spa-router-DrVOBVGg.d.ts → spa-router-CcejECnG.d.ts} +2 -2
- package/dist/{spa-router-w4aFOuyn.d.mts → spa-router-DgsMXqfX.d.mts} +2 -2
- package/dist/ssg-1FGaFISl.d.ts +184 -0
- package/dist/ssg-Bg4bMMhM.d.mts +184 -0
- package/dist/storage.cjs +6 -2
- package/dist/storage.d.mts +9 -1
- package/dist/storage.d.ts +9 -1
- package/dist/storage.mjs +5 -1
- package/dist/testing.cjs +20 -18
- package/dist/testing.d.mts +7 -9
- package/dist/testing.d.ts +7 -9
- package/dist/testing.mjs +16 -14
- package/dist/theme/server.cjs +4 -4
- package/dist/theme/server.mjs +3 -3
- package/dist/{utils-Dhuqwmd2.d.ts → utils-8wtTYiH4.d.mts} +1 -1
- package/dist/{utils-BtYehqeU.d.mts → utils-Dxbh6Hgj.d.ts} +1 -1
- package/dist/version.cjs +2 -2
- package/dist/version.mjs +1 -1
- package/dist/vite.cjs +75 -46
- package/dist/vite.d.mts +130 -11
- package/dist/vite.d.ts +130 -11
- package/dist/vite.mjs +76 -47
- package/dist/{workflows-jZ4BcdoZ.d.ts → workflows-IWP1ddBm.d.mts} +5 -2
- package/dist/{workflows-jZ4BcdoZ.d.mts → workflows-IWP1ddBm.d.ts} +5 -2
- package/dist/workflows.cjs +4 -3
- package/dist/workflows.d.mts +1 -1
- package/dist/workflows.d.ts +1 -1
- package/dist/workflows.mjs +3 -2
- package/package.json +3 -1
- package/dist/chunk-3SDFA7UF.cjs +0 -701
- package/dist/chunk-DAO7JGTS.mjs +0 -73
- package/dist/chunk-E5GNDG5F.mjs +0 -701
- package/dist/chunk-SYQ3MOWW.cjs +0 -73
- package/dist/chunk-ULASELLA.cjs +0 -48
- package/dist/integration-orm-55F7CII5.cjs +0 -13
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
|
+
|
|
3
|
+
var _chunkS3JO3N4Hcjs = require('./chunk-S3JO3N4H.cjs');
|
|
4
|
+
|
|
5
|
+
// src/server/request-bridge.ts
|
|
6
|
+
var CURRENT_REQUEST_RESOLVER_KEY = /* @__PURE__ */ Symbol.for("farm.currentRequestResolver");
|
|
7
|
+
var CURRENT_REQUEST_PEEK_KEY = /* @__PURE__ */ Symbol.for("farm.currentRequestPeek");
|
|
8
|
+
var APP_REQUEST_VIEW_KEY = /* @__PURE__ */ Symbol.for("farm.appRequestView");
|
|
9
|
+
function getGlobalState() {
|
|
10
|
+
return globalThis;
|
|
11
|
+
}
|
|
12
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, getGlobalState, "getGlobalState");
|
|
13
|
+
function _setCurrentRequestResolver(resolver, peek = resolver) {
|
|
14
|
+
const state = getGlobalState();
|
|
15
|
+
state[CURRENT_REQUEST_RESOLVER_KEY] = resolver;
|
|
16
|
+
state[CURRENT_REQUEST_PEEK_KEY] = peek;
|
|
17
|
+
}
|
|
18
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _setCurrentRequestResolver, "_setCurrentRequestResolver");
|
|
19
|
+
function _resolveCurrentRequest() {
|
|
20
|
+
return _optionalChain([getGlobalState, 'call', _ => _(), 'access', _2 => _2[CURRENT_REQUEST_RESOLVER_KEY], 'optionalCall', _3 => _3()]);
|
|
21
|
+
}
|
|
22
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _resolveCurrentRequest, "_resolveCurrentRequest");
|
|
23
|
+
function _peekCurrentRequest() {
|
|
24
|
+
const state = getGlobalState();
|
|
25
|
+
return _optionalChain([(_nullishCoalesce(state[CURRENT_REQUEST_PEEK_KEY], () => ( state[CURRENT_REQUEST_RESOLVER_KEY]))), 'optionalCall', _4 => _4()]);
|
|
26
|
+
}
|
|
27
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _peekCurrentRequest, "_peekCurrentRequest");
|
|
28
|
+
function _setAppRequestView(view) {
|
|
29
|
+
getGlobalState()[APP_REQUEST_VIEW_KEY] = view;
|
|
30
|
+
}
|
|
31
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _setAppRequestView, "_setAppRequestView");
|
|
32
|
+
function _resolveCurrentRequestForApp() {
|
|
33
|
+
const request = _peekCurrentRequest();
|
|
34
|
+
return request && _toAppRequestView(request);
|
|
35
|
+
}
|
|
36
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _resolveCurrentRequestForApp, "_resolveCurrentRequestForApp");
|
|
37
|
+
function _toAppRequestView(request) {
|
|
38
|
+
const view = getGlobalState()[APP_REQUEST_VIEW_KEY];
|
|
39
|
+
return view ? view(request) : request;
|
|
40
|
+
}
|
|
41
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _toAppRequestView, "_toAppRequestView");
|
|
42
|
+
var CSP_NONCE_RESOLVER_KEY = /* @__PURE__ */ Symbol.for("farm.cspNonceResolver");
|
|
43
|
+
function _setCspNonceResolver(resolver) {
|
|
44
|
+
globalThis[CSP_NONCE_RESOLVER_KEY] = resolver;
|
|
45
|
+
}
|
|
46
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _setCspNonceResolver, "_setCspNonceResolver");
|
|
47
|
+
function _resolveCurrentCspNonce() {
|
|
48
|
+
const resolver = globalThis[CSP_NONCE_RESOLVER_KEY];
|
|
49
|
+
return _optionalChain([resolver, 'optionalCall', _5 => _5()]);
|
|
50
|
+
}
|
|
51
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _resolveCurrentCspNonce, "_resolveCurrentCspNonce");
|
|
52
|
+
var SHARED_CACHE_SCOPE_RUNNER_KEY = /* @__PURE__ */ Symbol.for("farm.sharedCacheScopeRunner");
|
|
53
|
+
function _setSharedCacheScopeRunner(runner) {
|
|
54
|
+
globalThis[SHARED_CACHE_SCOPE_RUNNER_KEY] = runner;
|
|
55
|
+
}
|
|
56
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _setSharedCacheScopeRunner, "_setSharedCacheScopeRunner");
|
|
57
|
+
function _runInSharedCacheScope(label, fn) {
|
|
58
|
+
const runner = globalThis[SHARED_CACHE_SCOPE_RUNNER_KEY];
|
|
59
|
+
return runner ? runner(label, fn) : fn();
|
|
60
|
+
}
|
|
61
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, _runInSharedCacheScope, "_runInSharedCacheScope");
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
exports._setCurrentRequestResolver = _setCurrentRequestResolver; exports._resolveCurrentRequest = _resolveCurrentRequest; exports._peekCurrentRequest = _peekCurrentRequest; exports._setAppRequestView = _setAppRequestView; exports._resolveCurrentRequestForApp = _resolveCurrentRequestForApp; exports._toAppRequestView = _toAppRequestView; exports._setCspNonceResolver = _setCspNonceResolver; exports._resolveCurrentCspNonce = _resolveCurrentCspNonce; exports._setSharedCacheScopeRunner = _setSharedCacheScopeRunner; exports._runInSharedCacheScope = _runInSharedCacheScope;
|
|
@@ -4,29 +4,41 @@ import {
|
|
|
4
4
|
|
|
5
5
|
// src/server/request-bridge.ts
|
|
6
6
|
var CURRENT_REQUEST_RESOLVER_KEY = /* @__PURE__ */ Symbol.for("farm.currentRequestResolver");
|
|
7
|
+
var CURRENT_REQUEST_PEEK_KEY = /* @__PURE__ */ Symbol.for("farm.currentRequestPeek");
|
|
7
8
|
var APP_REQUEST_VIEW_KEY = /* @__PURE__ */ Symbol.for("farm.appRequestView");
|
|
8
9
|
function getGlobalState() {
|
|
9
10
|
return globalThis;
|
|
10
11
|
}
|
|
11
12
|
__name(getGlobalState, "getGlobalState");
|
|
12
|
-
function _setCurrentRequestResolver(resolver) {
|
|
13
|
-
getGlobalState()
|
|
13
|
+
function _setCurrentRequestResolver(resolver, peek = resolver) {
|
|
14
|
+
const state = getGlobalState();
|
|
15
|
+
state[CURRENT_REQUEST_RESOLVER_KEY] = resolver;
|
|
16
|
+
state[CURRENT_REQUEST_PEEK_KEY] = peek;
|
|
14
17
|
}
|
|
15
18
|
__name(_setCurrentRequestResolver, "_setCurrentRequestResolver");
|
|
16
19
|
function _resolveCurrentRequest() {
|
|
17
20
|
return getGlobalState()[CURRENT_REQUEST_RESOLVER_KEY]?.();
|
|
18
21
|
}
|
|
19
22
|
__name(_resolveCurrentRequest, "_resolveCurrentRequest");
|
|
23
|
+
function _peekCurrentRequest() {
|
|
24
|
+
const state = getGlobalState();
|
|
25
|
+
return (state[CURRENT_REQUEST_PEEK_KEY] ?? state[CURRENT_REQUEST_RESOLVER_KEY])?.();
|
|
26
|
+
}
|
|
27
|
+
__name(_peekCurrentRequest, "_peekCurrentRequest");
|
|
20
28
|
function _setAppRequestView(view) {
|
|
21
29
|
getGlobalState()[APP_REQUEST_VIEW_KEY] = view;
|
|
22
30
|
}
|
|
23
31
|
__name(_setAppRequestView, "_setAppRequestView");
|
|
24
32
|
function _resolveCurrentRequestForApp() {
|
|
25
|
-
const request =
|
|
26
|
-
|
|
27
|
-
return request && view ? view(request) : request;
|
|
33
|
+
const request = _peekCurrentRequest();
|
|
34
|
+
return request && _toAppRequestView(request);
|
|
28
35
|
}
|
|
29
36
|
__name(_resolveCurrentRequestForApp, "_resolveCurrentRequestForApp");
|
|
37
|
+
function _toAppRequestView(request) {
|
|
38
|
+
const view = getGlobalState()[APP_REQUEST_VIEW_KEY];
|
|
39
|
+
return view ? view(request) : request;
|
|
40
|
+
}
|
|
41
|
+
__name(_toAppRequestView, "_toAppRequestView");
|
|
30
42
|
var CSP_NONCE_RESOLVER_KEY = /* @__PURE__ */ Symbol.for("farm.cspNonceResolver");
|
|
31
43
|
function _setCspNonceResolver(resolver) {
|
|
32
44
|
globalThis[CSP_NONCE_RESOLVER_KEY] = resolver;
|
|
@@ -37,12 +49,26 @@ function _resolveCurrentCspNonce() {
|
|
|
37
49
|
return resolver?.();
|
|
38
50
|
}
|
|
39
51
|
__name(_resolveCurrentCspNonce, "_resolveCurrentCspNonce");
|
|
52
|
+
var SHARED_CACHE_SCOPE_RUNNER_KEY = /* @__PURE__ */ Symbol.for("farm.sharedCacheScopeRunner");
|
|
53
|
+
function _setSharedCacheScopeRunner(runner) {
|
|
54
|
+
globalThis[SHARED_CACHE_SCOPE_RUNNER_KEY] = runner;
|
|
55
|
+
}
|
|
56
|
+
__name(_setSharedCacheScopeRunner, "_setSharedCacheScopeRunner");
|
|
57
|
+
function _runInSharedCacheScope(label, fn) {
|
|
58
|
+
const runner = globalThis[SHARED_CACHE_SCOPE_RUNNER_KEY];
|
|
59
|
+
return runner ? runner(label, fn) : fn();
|
|
60
|
+
}
|
|
61
|
+
__name(_runInSharedCacheScope, "_runInSharedCacheScope");
|
|
40
62
|
|
|
41
63
|
export {
|
|
42
64
|
_setCurrentRequestResolver,
|
|
43
65
|
_resolveCurrentRequest,
|
|
66
|
+
_peekCurrentRequest,
|
|
44
67
|
_setAppRequestView,
|
|
45
68
|
_resolveCurrentRequestForApp,
|
|
69
|
+
_toAppRequestView,
|
|
46
70
|
_setCspNonceResolver,
|
|
47
|
-
_resolveCurrentCspNonce
|
|
71
|
+
_resolveCurrentCspNonce,
|
|
72
|
+
_setSharedCacheScopeRunner,
|
|
73
|
+
_runInSharedCacheScope
|
|
48
74
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } async function _asyncNullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return await rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkGS3WR5HXcjs = require('./chunk-GS3WR5HX.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkLIUGYUX3cjs = require('./chunk-LIUGYUX3.cjs');
|
|
@@ -17,6 +17,9 @@ var _chunkNYJMY3JAcjs = require('./chunk-NYJMY3JA.cjs');
|
|
|
17
17
|
var _chunkZEG3OPIBcjs = require('./chunk-ZEG3OPIB.cjs');
|
|
18
18
|
|
|
19
19
|
|
|
20
|
+
var _chunk6IZWX6EScjs = require('./chunk-6IZWX6ES.cjs');
|
|
21
|
+
|
|
22
|
+
|
|
20
23
|
var _chunkS3JO3N4Hcjs = require('./chunk-S3JO3N4H.cjs');
|
|
21
24
|
|
|
22
25
|
// src/cache-invalidation-stream.ts
|
|
@@ -208,6 +211,7 @@ async function encodeStorageKeySegment(value) {
|
|
|
208
211
|
}
|
|
209
212
|
_chunkS3JO3N4Hcjs.__name.call(void 0, encodeStorageKeySegment, "encodeStorageKeySegment");
|
|
210
213
|
var MIN_STALE_RETENTION_MS = 6e4;
|
|
214
|
+
var PPR_SHELL_ADAPTER_TTL_SECONDS = 86400;
|
|
211
215
|
function getFarmCacheEntryExpiresAt(createdAt, revalidate, now = Date.now()) {
|
|
212
216
|
if (typeof revalidate !== "number") return void 0;
|
|
213
217
|
const revalidateMs = revalidate * 1e3;
|
|
@@ -232,6 +236,8 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
232
236
|
this.namespace = "farm";
|
|
233
237
|
this.local = true;
|
|
234
238
|
this.maxEntries = 1024;
|
|
239
|
+
this.config = {};
|
|
240
|
+
this.isShellCache = false;
|
|
235
241
|
this.lease = {
|
|
236
242
|
enabled: true,
|
|
237
243
|
ttlMs: 1e4,
|
|
@@ -241,6 +247,8 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
241
247
|
this.configure(config);
|
|
242
248
|
}
|
|
243
249
|
configure(config = {}) {
|
|
250
|
+
this.config = config;
|
|
251
|
+
_optionalChain([this, 'access', _17 => _17.shells, 'optionalAccess', _18 => _18.configure, 'call', _19 => _19(config)]);
|
|
244
252
|
this.generation++;
|
|
245
253
|
this.entries.clear();
|
|
246
254
|
this.entriesByTag.clear();
|
|
@@ -254,21 +262,34 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
254
262
|
this.maxEntries = normalizePositiveInteger(config.maxEntries, 1024, "cache.maxEntries");
|
|
255
263
|
this.lease = config.lease === false ? { ...this.lease, enabled: false } : {
|
|
256
264
|
enabled: true,
|
|
257
|
-
ttlMs: normalizePositiveDuration(_optionalChain([config, 'access',
|
|
265
|
+
ttlMs: normalizePositiveDuration(_optionalChain([config, 'access', _20 => _20.lease, 'optionalAccess', _21 => _21.ttlMs]), 1e4, "cache.lease.ttlMs"),
|
|
258
266
|
waitTimeoutMs: normalizePositiveDuration(
|
|
259
|
-
_optionalChain([config, 'access',
|
|
267
|
+
_optionalChain([config, 'access', _22 => _22.lease, 'optionalAccess', _23 => _23.waitTimeoutMs]),
|
|
260
268
|
1e4,
|
|
261
269
|
"cache.lease.waitTimeoutMs"
|
|
262
270
|
),
|
|
263
271
|
pollIntervalMs: normalizePositiveDuration(
|
|
264
|
-
_optionalChain([config, 'access',
|
|
272
|
+
_optionalChain([config, 'access', _24 => _24.lease, 'optionalAccess', _25 => _25.pollIntervalMs]),
|
|
265
273
|
25,
|
|
266
274
|
"cache.lease.pollIntervalMs"
|
|
267
275
|
)
|
|
268
276
|
};
|
|
269
277
|
}
|
|
278
|
+
/**
|
|
279
|
+
* Where PPR shells live: the same adapter and namespace, so path and tag invalidation
|
|
280
|
+
* reaches them, but their own in-memory LRU of `maxEntries`.
|
|
281
|
+
* @internal
|
|
282
|
+
*/
|
|
283
|
+
get pprShellCache() {
|
|
284
|
+
if (this.isShellCache) return this;
|
|
285
|
+
if (!this.shells) {
|
|
286
|
+
this.shells = new _FarmDataCache(this.config);
|
|
287
|
+
this.shells.isShellCache = true;
|
|
288
|
+
}
|
|
289
|
+
return this.shells;
|
|
290
|
+
}
|
|
270
291
|
get adapterName() {
|
|
271
|
-
return _optionalChain([this, 'access',
|
|
292
|
+
return _optionalChain([this, 'access', _26 => _26.adapter, 'optionalAccess', _27 => _27.name]) || (this.adapter ? "custom" : "memory");
|
|
272
293
|
}
|
|
273
294
|
get hasAdapter() {
|
|
274
295
|
return this.adapter !== void 0;
|
|
@@ -277,17 +298,17 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
277
298
|
return this.entries.size;
|
|
278
299
|
}
|
|
279
300
|
get(key, options = {}) {
|
|
280
|
-
return _optionalChain([this, 'access',
|
|
301
|
+
return _optionalChain([this, 'access', _28 => _28.getEntry, 'call', _29 => _29(key, options), 'optionalAccess', _30 => _30.value]);
|
|
281
302
|
}
|
|
282
303
|
getEntry(key, options = {}) {
|
|
283
304
|
const entry = this.entries.get(key);
|
|
284
305
|
if (!entry) {
|
|
285
|
-
|
|
306
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.miss", key });
|
|
286
307
|
return void 0;
|
|
287
308
|
}
|
|
288
309
|
const stale = this.isStale(entry, options.now);
|
|
289
310
|
if (stale) {
|
|
290
|
-
|
|
311
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
291
312
|
type: "cache.stale",
|
|
292
313
|
key,
|
|
293
314
|
tags: Array.from(entry.tags),
|
|
@@ -295,11 +316,11 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
295
316
|
});
|
|
296
317
|
}
|
|
297
318
|
if (!options.allowStale && stale) {
|
|
298
|
-
|
|
319
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.miss", key, reason: "stale" });
|
|
299
320
|
return void 0;
|
|
300
321
|
}
|
|
301
322
|
this.touchEntry(key, entry);
|
|
302
|
-
|
|
323
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
303
324
|
type: "cache.hit",
|
|
304
325
|
key,
|
|
305
326
|
tags: Array.from(entry.tags),
|
|
@@ -322,34 +343,34 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
322
343
|
const entry = await adapter.get(`${namespace}:entry:${key}`);
|
|
323
344
|
if (generation !== this.generation) return void 0;
|
|
324
345
|
if (!entry || isForeignAdapterEntry(entry, key)) {
|
|
325
|
-
|
|
346
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.miss", key, ...entry ? { reason: "key-mismatch" } : {} });
|
|
326
347
|
return void 0;
|
|
327
348
|
}
|
|
328
349
|
assertFarmCacheEntry(entry, key);
|
|
329
350
|
if (typeof entry.expiresAt === "number" && entry.expiresAt <= (_nullishCoalesce(options.now, () => ( Date.now())))) {
|
|
330
|
-
|
|
351
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.miss", key, reason: "expired" });
|
|
331
352
|
try {
|
|
332
353
|
await adapter.delete(`${namespace}:entry:${key}`);
|
|
333
354
|
} catch (error) {
|
|
334
|
-
|
|
355
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.error", key, operation: "delete", error });
|
|
335
356
|
}
|
|
336
357
|
return void 0;
|
|
337
358
|
}
|
|
338
359
|
const stale = await this.isAdapterEntryStale(entry, options.now, adapter, namespace);
|
|
339
360
|
if (generation !== this.generation) return void 0;
|
|
340
361
|
if (stale) {
|
|
341
|
-
|
|
362
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
342
363
|
type: "cache.stale",
|
|
343
364
|
key,
|
|
344
365
|
tags: [...entry.tags],
|
|
345
366
|
revalidate: entry.revalidate
|
|
346
367
|
});
|
|
347
368
|
if (!options.allowStale) {
|
|
348
|
-
|
|
369
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.miss", key, reason: "stale" });
|
|
349
370
|
return void 0;
|
|
350
371
|
}
|
|
351
372
|
}
|
|
352
|
-
|
|
373
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
353
374
|
type: "cache.hit",
|
|
354
375
|
key,
|
|
355
376
|
tags: [...entry.tags],
|
|
@@ -380,7 +401,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
380
401
|
revalidate
|
|
381
402
|
};
|
|
382
403
|
this.storeLocalEntry(entry);
|
|
383
|
-
|
|
404
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
384
405
|
type: "cache.set",
|
|
385
406
|
key,
|
|
386
407
|
tags: Array.from(tags),
|
|
@@ -396,7 +417,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
396
417
|
const tags = normalizeCacheOptionsTags(options);
|
|
397
418
|
const capturedVersions = await _asyncNullishCoalesce(tagVersions, async () => ( await this.getAdapterTagVersions(Array.from(tags.values()))));
|
|
398
419
|
const createdAt = _nullishCoalesce(options.createdAt, () => ( Date.now()));
|
|
399
|
-
const expiresAt = getFarmCacheEntryExpiresAt(createdAt, revalidate);
|
|
420
|
+
const expiresAt = _nullishCoalesce(getFarmCacheEntryExpiresAt(createdAt, revalidate), () => ( (this.isShellCache && this.adapter ? createdAt + PPR_SHELL_ADAPTER_TTL_SECONDS * 1e3 : void 0)));
|
|
400
421
|
const entry = {
|
|
401
422
|
key,
|
|
402
423
|
value,
|
|
@@ -413,7 +434,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
413
434
|
if (this.adapter) {
|
|
414
435
|
await this.adapter.set(this.createAdapterKey(key), entry);
|
|
415
436
|
}
|
|
416
|
-
|
|
437
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
417
438
|
type: "cache.set",
|
|
418
439
|
key,
|
|
419
440
|
tags: [...entry.tags],
|
|
@@ -423,7 +444,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
423
444
|
}
|
|
424
445
|
delete(key) {
|
|
425
446
|
const deleted = this.deleteLocalEntry(key);
|
|
426
|
-
|
|
447
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.delete", key, deleted });
|
|
427
448
|
return deleted;
|
|
428
449
|
}
|
|
429
450
|
async deleteAsync(key) {
|
|
@@ -431,10 +452,15 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
431
452
|
if (this.adapter) {
|
|
432
453
|
await this.adapter.delete(this.createAdapterKey(key));
|
|
433
454
|
}
|
|
434
|
-
|
|
455
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.delete", key, deleted: this.adapter ? true : deleted });
|
|
435
456
|
return this.adapter ? true : deleted;
|
|
436
457
|
}
|
|
437
458
|
clear() {
|
|
459
|
+
const count = this.entries.size + (_nullishCoalesce(_optionalChain([this, 'access', _31 => _31.shells, 'optionalAccess', _32 => _32.resetLocal, 'call', _33 => _33()]), () => ( 0)));
|
|
460
|
+
this.resetLocal();
|
|
461
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.clear", count });
|
|
462
|
+
}
|
|
463
|
+
resetLocal() {
|
|
438
464
|
const count = this.entries.size;
|
|
439
465
|
this.generation++;
|
|
440
466
|
this.entries.clear();
|
|
@@ -443,11 +469,11 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
443
469
|
this.invalidatedTagVersions.clear();
|
|
444
470
|
this.activeGenerations.clear();
|
|
445
471
|
this.version = 0;
|
|
446
|
-
|
|
472
|
+
return count;
|
|
447
473
|
}
|
|
448
474
|
async clearAsync() {
|
|
449
475
|
this.clear();
|
|
450
|
-
await _optionalChain([this, 'access',
|
|
476
|
+
await _optionalChain([this, 'access', _34 => _34.adapter, 'optionalAccess', _35 => _35.clear, 'optionalCall', _36 => _36()]);
|
|
451
477
|
}
|
|
452
478
|
isStale(entry, now = Date.now()) {
|
|
453
479
|
if (typeof entry.revalidate === "number" && entry.revalidate >= 0 && now - entry.createdAt >= entry.revalidate * 1e3) {
|
|
@@ -469,17 +495,17 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
469
495
|
}
|
|
470
496
|
revalidateTag(tag, options = {}) {
|
|
471
497
|
const normalized = normalizeCacheTag(tag);
|
|
472
|
-
const count = this.invalidateTag(normalized);
|
|
473
|
-
|
|
498
|
+
const count = this.invalidateTag(normalized) + (_nullishCoalesce(_optionalChain([this, 'access', _37 => _37.shells, 'optionalAccess', _38 => _38.invalidateTag, 'call', _39 => _39(normalized)]), () => ( 0)));
|
|
499
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0,
|
|
474
500
|
options.source === "updateTag" ? { type: "cache.updateTag", tag: normalized, count } : { type: "cache.revalidateTag", tag: normalized, profile: options.profile, count }
|
|
475
501
|
);
|
|
476
502
|
return count;
|
|
477
503
|
}
|
|
478
504
|
async revalidateTagAsync(tag, options = {}) {
|
|
479
505
|
const normalized = normalizeCacheTag(tag);
|
|
480
|
-
const count = this.invalidateTag(normalized);
|
|
481
|
-
await _optionalChain([this, 'access',
|
|
482
|
-
|
|
506
|
+
const count = this.invalidateTag(normalized) + (_nullishCoalesce(_optionalChain([this, 'access', _40 => _40.shells, 'optionalAccess', _41 => _41.invalidateTag, 'call', _42 => _42(normalized)]), () => ( 0)));
|
|
507
|
+
await _optionalChain([this, 'access', _43 => _43.adapter, 'optionalAccess', _44 => _44.invalidateTags, 'optionalCall', _45 => _45([this.createAdapterTag(normalized)])]);
|
|
508
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0,
|
|
483
509
|
options.source === "updateTag" ? { type: "cache.updateTag", tag: normalized, count } : { type: "cache.revalidateTag", tag: normalized, profile: options.profile, count }
|
|
484
510
|
);
|
|
485
511
|
return count;
|
|
@@ -487,11 +513,11 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
487
513
|
revalidatePath(routePath) {
|
|
488
514
|
const normalizedPath = normalizeRevalidatePath(routePath);
|
|
489
515
|
const pathTag = createPathCacheTag(normalizedPath);
|
|
490
|
-
const pprCount = this.countEntriesForTags([pathTag, "ppr"]);
|
|
491
|
-
const count = this.invalidateTag(pathTag);
|
|
492
|
-
|
|
516
|
+
const pprCount = this.countEntriesForTags([pathTag, "ppr"]) + (_nullishCoalesce(_optionalChain([this, 'access', _46 => _46.shells, 'optionalAccess', _47 => _47.countEntriesForTags, 'call', _48 => _48([pathTag, "ppr"])]), () => ( 0)));
|
|
517
|
+
const count = this.invalidateTag(pathTag) + (_nullishCoalesce(_optionalChain([this, 'access', _49 => _49.shells, 'optionalAccess', _50 => _50.invalidateTag, 'call', _51 => _51(pathTag)]), () => ( 0)));
|
|
518
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.revalidatePath", path: normalizedPath, count });
|
|
493
519
|
if (pprCount > 0) {
|
|
494
|
-
|
|
520
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
495
521
|
type: "ppr.shell.invalidated",
|
|
496
522
|
route: normalizedPath,
|
|
497
523
|
reason: "revalidatePath",
|
|
@@ -503,12 +529,12 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
503
529
|
async revalidatePathAsync(routePath) {
|
|
504
530
|
const normalizedPath = normalizeRevalidatePath(routePath);
|
|
505
531
|
const pathTag = createPathCacheTag(normalizedPath);
|
|
506
|
-
const pprCount = this.countEntriesForTags([pathTag, "ppr"]);
|
|
507
|
-
const count = this.invalidateTag(pathTag);
|
|
508
|
-
await _optionalChain([this, 'access',
|
|
509
|
-
|
|
532
|
+
const pprCount = this.countEntriesForTags([pathTag, "ppr"]) + (_nullishCoalesce(_optionalChain([this, 'access', _52 => _52.shells, 'optionalAccess', _53 => _53.countEntriesForTags, 'call', _54 => _54([pathTag, "ppr"])]), () => ( 0)));
|
|
533
|
+
const count = this.invalidateTag(pathTag) + (_nullishCoalesce(_optionalChain([this, 'access', _55 => _55.shells, 'optionalAccess', _56 => _56.invalidateTag, 'call', _57 => _57(pathTag)]), () => ( 0)));
|
|
534
|
+
await _optionalChain([this, 'access', _58 => _58.adapter, 'optionalAccess', _59 => _59.invalidateTags, 'optionalCall', _60 => _60([this.createAdapterTag(pathTag)])]);
|
|
535
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.revalidatePath", path: normalizedPath, count });
|
|
510
536
|
if (pprCount > 0) {
|
|
511
|
-
|
|
537
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
512
538
|
type: "ppr.shell.invalidated",
|
|
513
539
|
route: normalizedPath,
|
|
514
540
|
reason: "revalidatePath",
|
|
@@ -525,17 +551,17 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
525
551
|
}
|
|
526
552
|
const inflight = this.inflight.get(key);
|
|
527
553
|
if (inflight && !this.wasInvalidatedSince(inflight.tags, inflight.startVersion)) {
|
|
528
|
-
|
|
554
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.dedupe", key });
|
|
529
555
|
return inflight.promise;
|
|
530
556
|
}
|
|
531
557
|
const tags = Array.from(normalizeCacheOptionsTags(options));
|
|
532
558
|
const generation = this.generation;
|
|
533
559
|
const startVersion = this.version;
|
|
534
560
|
const promise = this.fillCacheEntry(key, producer, options, tags, generation).catch((error) => {
|
|
535
|
-
|
|
561
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.error", key, operation: "set", error });
|
|
536
562
|
throw error;
|
|
537
563
|
}).finally(() => {
|
|
538
|
-
if (_optionalChain([this, 'access',
|
|
564
|
+
if (_optionalChain([this, 'access', _61 => _61.inflight, 'access', _62 => _62.get, 'call', _63 => _63(key), 'optionalAccess', _64 => _64.promise]) === promise) {
|
|
539
565
|
this.inflight.delete(key);
|
|
540
566
|
}
|
|
541
567
|
});
|
|
@@ -556,7 +582,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
556
582
|
const lease = { ...this.lease };
|
|
557
583
|
const leaseKey = `${namespace}:lease:${key}`;
|
|
558
584
|
let leaseToken;
|
|
559
|
-
if (_optionalChain([adapter, 'optionalAccess',
|
|
585
|
+
if (_optionalChain([adapter, 'optionalAccess', _65 => _65.acquireLease]) && adapter.releaseLease && lease.enabled) {
|
|
560
586
|
leaseToken = await adapter.acquireLease(leaseKey, lease.ttlMs);
|
|
561
587
|
if (!leaseToken) {
|
|
562
588
|
const shared = await this.waitForAdapterEntry(
|
|
@@ -567,7 +593,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
567
593
|
generation
|
|
568
594
|
);
|
|
569
595
|
if (shared) {
|
|
570
|
-
|
|
596
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.dedupe", key });
|
|
571
597
|
return shared.value;
|
|
572
598
|
}
|
|
573
599
|
if (generation === this.generation) {
|
|
@@ -591,11 +617,11 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
591
617
|
} finally {
|
|
592
618
|
this.activeGenerations.delete(activeGeneration);
|
|
593
619
|
this.pruneInvalidatedTagVersions(activeGeneration.tags);
|
|
594
|
-
if (leaseToken && _optionalChain([adapter, 'optionalAccess',
|
|
620
|
+
if (leaseToken && _optionalChain([adapter, 'optionalAccess', _66 => _66.releaseLease])) {
|
|
595
621
|
try {
|
|
596
622
|
await adapter.releaseLease(leaseKey, leaseToken);
|
|
597
623
|
} catch (error) {
|
|
598
|
-
|
|
624
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.error", key, operation: "set", error });
|
|
599
625
|
}
|
|
600
626
|
}
|
|
601
627
|
}
|
|
@@ -608,22 +634,22 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
608
634
|
const entry = await adapter.get(`${namespace}:entry:${key}`);
|
|
609
635
|
if (generation !== this.generation) return void 0;
|
|
610
636
|
if (!entry || isForeignAdapterEntry(entry, key)) {
|
|
611
|
-
|
|
637
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.miss", key, ...entry ? { reason: "key-mismatch" } : {} });
|
|
612
638
|
continue;
|
|
613
639
|
}
|
|
614
640
|
assertFarmCacheEntry(entry, key);
|
|
615
641
|
const stale = await this.isAdapterEntryStale(entry, Date.now(), adapter, namespace);
|
|
616
642
|
if (generation !== this.generation) return void 0;
|
|
617
643
|
if (stale) {
|
|
618
|
-
|
|
644
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
619
645
|
type: "cache.stale",
|
|
620
646
|
key,
|
|
621
647
|
tags: [...entry.tags],
|
|
622
648
|
revalidate: entry.revalidate
|
|
623
649
|
});
|
|
624
|
-
|
|
650
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "cache.miss", key, reason: "stale" });
|
|
625
651
|
} else {
|
|
626
|
-
|
|
652
|
+
_chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
|
|
627
653
|
type: "cache.hit",
|
|
628
654
|
key,
|
|
629
655
|
tags: [...entry.tags],
|
|
@@ -645,7 +671,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
645
671
|
return count;
|
|
646
672
|
}
|
|
647
673
|
invalidateTag(normalizedTag) {
|
|
648
|
-
const count = _nullishCoalesce(_optionalChain([this, 'access',
|
|
674
|
+
const count = _nullishCoalesce(_optionalChain([this, 'access', _67 => _67.entriesByTag, 'access', _68 => _68.get, 'call', _69 => _69(normalizedTag), 'optionalAccess', _70 => _70.size]), () => ( 0));
|
|
649
675
|
this.invalidatedTagVersions.delete(normalizedTag);
|
|
650
676
|
this.invalidatedTagVersions.set(normalizedTag, ++this.version);
|
|
651
677
|
this.pruneInvalidatedTagVersions([normalizedTag]);
|
|
@@ -738,7 +764,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
738
764
|
return `${this.namespace}:tag:${tag}`;
|
|
739
765
|
}
|
|
740
766
|
async getAdapterTagVersions(tags, adapter = this.adapter, namespace = this.namespace) {
|
|
741
|
-
if (!_optionalChain([adapter, 'optionalAccess',
|
|
767
|
+
if (!_optionalChain([adapter, 'optionalAccess', _71 => _71.getTagVersions]) || tags.length === 0) return {};
|
|
742
768
|
const normalized = tags.map(normalizeCacheTag);
|
|
743
769
|
const physicalTags = normalized.map((tag) => `${namespace}:tag:${tag}`);
|
|
744
770
|
const versions = await adapter.getTagVersions(physicalTags);
|
|
@@ -755,7 +781,7 @@ var _FarmDataCache = class _FarmDataCache {
|
|
|
755
781
|
}
|
|
756
782
|
const currentVersions = await this.getAdapterTagVersions(entry.tags, adapter, namespace);
|
|
757
783
|
for (const tag of entry.tags) {
|
|
758
|
-
if (normalizeAdapterVersion(currentVersions[tag]) > normalizeAdapterVersion(_optionalChain([entry, 'access',
|
|
784
|
+
if (normalizeAdapterVersion(currentVersions[tag]) > normalizeAdapterVersion(_optionalChain([entry, 'access', _72 => _72.tagVersions, 'optionalAccess', _73 => _73[tag]]))) {
|
|
759
785
|
return true;
|
|
760
786
|
}
|
|
761
787
|
}
|
|
@@ -777,7 +803,7 @@ function configureFarmCache(config) {
|
|
|
777
803
|
_chunkS3JO3N4Hcjs.__name.call(void 0, configureFarmCache, "configureFarmCache");
|
|
778
804
|
function unstable_cache(fn, keyParts = [], options = {}) {
|
|
779
805
|
return async (...args) => {
|
|
780
|
-
const locale = _optionalChain([_chunkLIUGYUX3cjs.getActiveFarmI18nSnapshot.call(void 0, ), 'optionalAccess',
|
|
806
|
+
const locale = _optionalChain([_chunkLIUGYUX3cjs.getActiveFarmI18nSnapshot.call(void 0, ), 'optionalAccess', _74 => _74.locale]);
|
|
781
807
|
const key = _chunkNYJMY3JAcjs.createFarmCacheKey.call(void 0, [
|
|
782
808
|
"unstable_cache",
|
|
783
809
|
_chunkNYJMY3JAcjs.getFunctionCacheIdentity.call(void 0, fn),
|
|
@@ -785,7 +811,11 @@ function unstable_cache(fn, keyParts = [], options = {}) {
|
|
|
785
811
|
keyParts,
|
|
786
812
|
args
|
|
787
813
|
]);
|
|
788
|
-
return getFarmDataCache().getOrSet(
|
|
814
|
+
return getFarmDataCache().getOrSet(
|
|
815
|
+
key,
|
|
816
|
+
() => _chunk6IZWX6EScjs._runInSharedCacheScope.call(void 0, "unstable_cache()", () => fn(...args)),
|
|
817
|
+
options
|
|
818
|
+
);
|
|
789
819
|
};
|
|
790
820
|
}
|
|
791
821
|
_chunkS3JO3N4Hcjs.__name.call(void 0, unstable_cache, "unstable_cache");
|
|
@@ -999,4 +1029,5 @@ _chunkS3JO3N4Hcjs.__name.call(void 0, assertFarmCacheInvalidationTarget, "assert
|
|
|
999
1029
|
|
|
1000
1030
|
|
|
1001
1031
|
|
|
1002
|
-
|
|
1032
|
+
|
|
1033
|
+
exports.createFarmCacheInvalidationStream = createFarmCacheInvalidationStream; exports.defineCacheKey = defineCacheKey; exports.storageCacheAdapter = storageCacheAdapter; exports.PPR_SHELL_ADAPTER_TTL_SECONDS = PPR_SHELL_ADAPTER_TTL_SECONDS; exports.FarmDataCache = FarmDataCache; exports.getFarmDataCache = getFarmDataCache; exports.configureFarmCache = configureFarmCache; exports.unstable_cache = unstable_cache; exports.revalidateTag = revalidateTag; exports.updateTag = updateTag; exports.revalidatePath = revalidatePath; exports.invalidate = invalidate; exports.invalidateRouteData = invalidateRouteData; exports.applyFarmCacheInvalidationTargets = applyFarmCacheInvalidationTargets; exports.createPathCacheTag = createPathCacheTag; exports.createRouteDataCacheTag = createRouteDataCacheTag; exports.normalizeRevalidatePath = normalizeRevalidatePath;
|
|
@@ -12,8 +12,8 @@ import {
|
|
|
12
12
|
getFarmI18nClientState
|
|
13
13
|
} from "./chunk-IHQIOZLC.mjs";
|
|
14
14
|
import {
|
|
15
|
-
|
|
16
|
-
} from "./chunk-
|
|
15
|
+
_peekCurrentRequest
|
|
16
|
+
} from "./chunk-6LVRDOAW.mjs";
|
|
17
17
|
import {
|
|
18
18
|
stripFarmLocaleFromPathname
|
|
19
19
|
} from "./chunk-L3KT7IXV.mjs";
|
|
@@ -213,7 +213,7 @@ function readCurrentUrl() {
|
|
|
213
213
|
return void 0;
|
|
214
214
|
}
|
|
215
215
|
}
|
|
216
|
-
const request =
|
|
216
|
+
const request = _peekCurrentRequest();
|
|
217
217
|
if (!request) return void 0;
|
|
218
218
|
try {
|
|
219
219
|
return new URL(request.url);
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
var _chunkS3JO3N4Hcjs = require('./chunk-S3JO3N4H.cjs');
|
|
4
|
+
|
|
5
|
+
// src/plugin-integration-context.ts
|
|
6
|
+
var FARM_PLUGIN_INTEGRATION_CONTEXT = /* @__PURE__ */ Symbol.for("@farm.js/core/plugin-integration-context");
|
|
7
|
+
function setFarmPluginIntegrationContext(plugin, integration) {
|
|
8
|
+
Object.defineProperty(plugin, FARM_PLUGIN_INTEGRATION_CONTEXT, {
|
|
9
|
+
value: integration
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, setFarmPluginIntegrationContext, "setFarmPluginIntegrationContext");
|
|
13
|
+
function getFarmPluginIntegrationContext(plugin) {
|
|
14
|
+
const value = plugin[FARM_PLUGIN_INTEGRATION_CONTEXT];
|
|
15
|
+
return value && typeof value === "object" ? value : void 0;
|
|
16
|
+
}
|
|
17
|
+
_chunkS3JO3N4Hcjs.__name.call(void 0, getFarmPluginIntegrationContext, "getFarmPluginIntegrationContext");
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
exports.setFarmPluginIntegrationContext = setFarmPluginIntegrationContext; exports.getFarmPluginIntegrationContext = getFarmPluginIntegrationContext;
|