@builder.io/sdk-react 2.0.24-0 → 2.0.24-2
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/lib/browser/blocks-exports.cjs +1 -1
- package/lib/browser/blocks-exports.mjs +1 -1
- package/lib/browser/index.cjs +1 -1
- package/lib/browser/index.mjs +1 -1
- package/lib/browser/{server-entry-e7cbd2fc.js → server-entry-c147474a.js} +1 -1
- package/lib/browser/{server-entry-3855428f.cjs → server-entry-e66059f2.cjs} +1 -1
- package/lib/browser/server-entry.cjs +1 -1
- package/lib/browser/server-entry.mjs +1 -1
- package/lib/edge/{accordion-57df597a.js → accordion-5efe1f76.js} +1 -1
- package/lib/edge/{accordion-91147fe9.cjs → accordion-6cefa683.cjs} +1 -1
- package/lib/edge/{blocks-228052f4.js → blocks-47ceb648.js} +3 -3
- package/lib/edge/{blocks-2a92a0c1.cjs → blocks-ce41f8e2.cjs} +1 -1
- package/lib/edge/blocks-exports.cjs +1 -1
- package/lib/edge/blocks-exports.mjs +2 -2
- package/lib/edge/{button-ff78ab2a.cjs → button-375ad1e4.cjs} +1 -1
- package/lib/edge/{button-d681583e.js → button-68dc9c15.js} +2 -2
- package/lib/edge/{columns-354a8faf.cjs → columns-2ced7464.cjs} +1 -1
- package/lib/edge/{columns-59392fea.js → columns-fa195aa5.js} +4 -4
- package/lib/edge/{content-variants-f22b14d7.cjs → content-variants-12e2c711.cjs} +1 -1
- package/lib/edge/{content-variants-983cfed6.js → content-variants-b2ab5645.js} +11 -11
- package/lib/edge/{evaluate-f8347208.cjs → evaluate-71f3ff34.cjs} +1 -1
- package/lib/edge/{evaluate-b7da3191.js → evaluate-822680d7.js} +1 -1
- package/lib/edge/{form-52e60b8b.js → form-785f87de.js} +4 -4
- package/lib/edge/{form-2c8b99e2.cjs → form-eb6df3c0.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-956dc1ac.cjs → get-class-prop-name-20feabab.cjs} +1 -1
- package/lib/edge/{get-class-prop-name-8c8a1b1c.js → get-class-prop-name-dba1cf23.js} +1 -1
- package/lib/edge/{img-ce324880.js → img-9409566a.js} +1 -1
- package/lib/edge/{img-9e702744.cjs → img-df10057c.cjs} +1 -1
- package/lib/edge/index.cjs +1 -1
- package/lib/edge/index.mjs +1 -1
- package/lib/edge/{input-c5dda333.js → input-175da017.js} +1 -1
- package/lib/edge/{input-09bbebbb.cjs → input-ad5251cd.cjs} +1 -1
- package/lib/edge/{select-235baf48.cjs → select-c59da945.cjs} +1 -1
- package/lib/edge/{select-8936ea79.js → select-e6904df2.js} +1 -1
- package/lib/edge/{server-entry-f0d7962f.cjs → server-entry-2d057cd0.cjs} +1 -1
- package/lib/edge/{server-entry-b3befa52.js → server-entry-7d728f1e.js} +1 -1
- package/lib/edge/server-entry.cjs +1 -1
- package/lib/edge/server-entry.mjs +1 -1
- package/lib/edge/{slot-eb173f0a.cjs → slot-27d61c78.cjs} +1 -1
- package/lib/edge/{slot-f274570e.js → slot-a7fc3fa3.js} +4 -4
- package/lib/edge/{symbol-73a9d7cb.cjs → symbol-5cf11265.cjs} +1 -1
- package/lib/edge/{symbol-0deda8a7.js → symbol-d41cf7c4.js} +2 -2
- package/lib/edge/{tabs-4e5783b2.cjs → tabs-3a710ab1.cjs} +1 -1
- package/lib/edge/{tabs-791385cc.js → tabs-81ccc6f8.js} +4 -4
- package/lib/edge/{text-0a14d566.js → text-345dd047.js} +2 -2
- package/lib/edge/{text-3dd73c6e.cjs → text-59e297e6.cjs} +1 -1
- package/lib/node/blocks-exports.cjs +21 -21
- package/lib/node/blocks-exports.mjs +7 -6
- package/lib/node/index.cjs +1 -1
- package/lib/node/index.mjs +26 -25
- package/lib/node/init.cjs +1 -1
- package/lib/node/init.mjs +7 -6
- package/lib/node/{server-entry-a7139d8f.cjs → server-entry-1c1c1459.cjs} +1 -1
- package/lib/node/{server-entry-fa11b353.js → server-entry-8956b57e.js} +1 -1
- package/lib/node/server-entry.cjs +1 -1
- package/lib/node/server-entry.mjs +1 -1
- package/lib/node/{should-force-browser-runtime-in-node-ddb84649.js → setIvm-2e562b9e.js} +41 -55
- package/lib/node/{should-force-browser-runtime-in-node-0bf7076b.cjs → setIvm-bf4f998d.cjs} +4 -4
- package/lib/node/setIvm.cjs +1 -0
- package/lib/node/setIvm.mjs +5 -0
- package/lib/node/should-force-browser-runtime-in-node-a23d3cc4.js +17 -0
- package/lib/node/should-force-browser-runtime-in-node-ce6ededa.cjs +1 -0
- package/package.json +6 -1
- package/types/constants/sdk-version.d.ts +1 -1
- package/types/functions/evaluate/node-runtime/setIvm.d.ts +1 -0
package/lib/node/init.mjs
CHANGED
|
@@ -1,17 +1,18 @@
|
|
|
1
|
-
import { shouldForceBrowserRuntimeInNode as
|
|
2
|
-
import
|
|
3
|
-
import "./
|
|
1
|
+
import { shouldForceBrowserRuntimeInNode as r } from "./should-force-browser-runtime-in-node-a23d3cc4.js";
|
|
2
|
+
import t from "isolated-vm";
|
|
3
|
+
import { setIvm as e } from "./setIvm-2e562b9e.js";
|
|
4
|
+
import "./server-entry-8956b57e.js";
|
|
4
5
|
const u = (o) => {
|
|
5
|
-
if (
|
|
6
|
+
if (r({
|
|
6
7
|
shouldLogWarning: !0
|
|
7
8
|
}))
|
|
8
9
|
return;
|
|
9
10
|
const {
|
|
10
11
|
ivmIsolateOptions: i
|
|
11
12
|
} = o || {};
|
|
12
|
-
|
|
13
|
+
e(t, i);
|
|
13
14
|
};
|
|
14
15
|
export {
|
|
15
16
|
u as initializeNodeRuntime,
|
|
16
|
-
|
|
17
|
+
e as setIvm
|
|
17
18
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const I="react",b="[Builder.io]: ",d={log:(...e)=>console.log(b,...e),error:(...e)=>console.error(b,...e),warn:(...e)=>console.warn(b,...e),debug:(...e)=>console.debug(b,...e)};function c(){return typeof window!="undefined"&&typeof document!="undefined"}const ae=e=>{const t={};return e.forEach((n,r)=>{t[r]=n}),t},M=e=>e instanceof URLSearchParams?ae(e):e,U=e=>typeof e=="string"?e:e instanceof URLSearchParams?e.toString():new URLSearchParams(e).toString();function ce(){return c()&&window.self!==window.top}function F(e){return ce()&&U(e||window.location.search).indexOf("builder.frameEditing=")!==-1}const ue=()=>{if(c()){const e=new URL(location.href);return e.pathname===""&&(e.pathname="/"),e}else return console.warn("Cannot get location for tracking in non-browser environment"),null},de=()=>typeof navigator=="object"&&navigator.userAgent||"",N=()=>{const e=de(),t={Android(){return e.match(/Android/i)},BlackBerry(){return e.match(/BlackBerry/i)},iOS(){return e.match(/iPhone|iPod/i)},Opera(){return e.match(/Opera Mini/i)},Windows(){return e.match(/IEMobile/i)||e.match(/WPDesktop/i)},any(){return t.Android()||t.BlackBerry()||t.iOS()||t.Opera()||t.Windows()||I==="reactNative"}},n=e.match(/Tablet|iPad/i),r=ue();return{urlPath:r==null?void 0:r.pathname,host:(r==null?void 0:r.host)||(r==null?void 0:r.hostname),device:n?"tablet":t.any()?"mobile":"desktop"}},p=e=>e!=null;function le(e){const t=e||(c()?window.location.search:void 0);return t?U(t).indexOf("builder.preview=")!==-1:!1}const fe=e=>({type:"builder.registerComponent",data:k(e)}),ge=e=>{const t=e.toString().trim();return`return (${!t.startsWith("function")&&!t.startsWith("(")?"function ":""}${t}).apply(this, arguments)`};function k(e){return JSON.parse(JSON.stringify(e,(t,n)=>typeof n=="function"?ge(n):n))}const x={};function D(e,t){e==="plugin"&&(t=k(t));let n=x[e];if(n||(n=x[e]=[]),n.push(t),c()){const r={type:"builder.register",data:{type:e,info:t}};try{parent.postMessage(r,"*"),parent!==window&&window.postMessage(r,"*")}catch(o){console.debug("Could not postmessage",o)}}}const R={};function he(e){if(c()){Object.assign(R,e);const t={type:"builder.settingsChange",data:R};parent.postMessage(t,"*")}}const B="builder.",pe="options.",P=e=>{if(!e)return{};const t=M(e),n={};return Object.keys(t).forEach(r=>{if(r.startsWith(B)){const o=r.replace(B,"").replace(pe,"");n[o]=t[r]}}),n},me=()=>{if(!c())return{};const e=new URLSearchParams(window.location.search);return P(e)},ye=e=>{if(e==="localhost"||e==="127.0.0.1")return e;const t=e.split(".");return t.length>2?t.slice(1).join("."):e},j=({name:e,canTrack:t})=>{var n;try{return t?(n=document.cookie.split("; ").find(r=>r.startsWith(`${e}=`)))==null?void 0:n.split("=")[1]:void 0}catch(r){d.warn("[COOKIE] GET error: ",(r==null?void 0:r.message)||r);return}},K=async e=>j(e),Se=e=>e.map(([t,n])=>n?`${t}=${n}`:t).filter(p).join("; "),we=[["secure",""],["SameSite","None"]],be=({name:e,value:t,expires:n})=>{const o=(c()?location.protocol==="https:":!0)?we:[[]],s=n?[["expires",n.toUTCString()]]:[[]],a=[[e,t],...s,["path","/"],["domain",ye(window.location.hostname)],...o];return Se(a)},_=async({name:e,value:t,expires:n,canTrack:r})=>{try{if(!r)return;const o=be({name:e,value:t,expires:n});document.cookie=o}catch(o){d.warn("[COOKIE] SET error: ",(o==null?void 0:o.message)||o)}};function Ie(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e=="x"?t:t&3|8).toString(16)})}function W(){return Ie().replace(/-/g,"")}const $="builderSessionId",ve=async({canTrack:e})=>{if(!e)return;const t=await K({name:$,canTrack:e});if(p(t))return t;{const n=Ee();return ke({id:n,canTrack:e}),n}},Ee=()=>W(),ke=({id:e,canTrack:t})=>_({name:$,value:e,canTrack:t}),G=()=>c()&&typeof localStorage!="undefined"?localStorage:void 0,Pe=({key:e,canTrack:t})=>{var n;try{return t?(n=G())==null?void 0:n.getItem(e):void 0}catch(r){console.debug("[LocalStorage] GET error: ",r);return}},Ce=({key:e,canTrack:t,value:n})=>{var r;try{t&&((r=G())==null||r.setItem(e,n))}catch(o){console.debug("[LocalStorage] SET error: ",o)}},z="builderVisitorId",Oe=({canTrack:e})=>{if(!e)return;const t=Pe({key:z,canTrack:e});if(p(t))return t;{const n=Ae();return Te({id:n,canTrack:e}),n}},Ae=()=>W(),Te=({id:e,canTrack:t})=>Ce({key:z,value:e,canTrack:t}),xe=async({canTrack:e})=>{if(!e)return{visitorId:void 0,sessionId:void 0};const t=await ve({canTrack:e}),n=Oe({canTrack:e});return{sessionId:t,visitorId:n}},Re=async({type:e,canTrack:t,apiKey:n,metadata:r,...o})=>({type:e,data:{...o,metadata:{url:location.href,...r},...await xe({canTrack:t}),userAttributes:N(),ownerId:n}});async function J(e){if(!e.apiKey){d.error("Missing API key for track call. Please provide your API key.");return}if(e.canTrack&&!F()&&(c()||I==="reactNative"))return fetch("https://cdn.builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await Re(e)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(t=>{console.error("Failed to track: ",t)})}const Be=e=>J({...e,canTrack:!0}),Le=["*.beta.builder.io","beta.builder.io","builder.io","localhost","qa.builder.io"];function H(e,t){if(!t.origin.startsWith("http")&&!t.origin.startsWith("https"))return!1;const n=new URL(t.origin),r=n.hostname;return(e||Le).findIndex(o=>o.startsWith("*.")?r.endsWith(o.slice(1)):o===r)>-1}const Ve="2.0.
|
|
1
|
+
"use strict";const I="react",b="[Builder.io]: ",d={log:(...e)=>console.log(b,...e),error:(...e)=>console.error(b,...e),warn:(...e)=>console.warn(b,...e),debug:(...e)=>console.debug(b,...e)};function c(){return typeof window!="undefined"&&typeof document!="undefined"}const ae=e=>{const t={};return e.forEach((n,r)=>{t[r]=n}),t},M=e=>e instanceof URLSearchParams?ae(e):e,U=e=>typeof e=="string"?e:e instanceof URLSearchParams?e.toString():new URLSearchParams(e).toString();function ce(){return c()&&window.self!==window.top}function F(e){return ce()&&U(e||window.location.search).indexOf("builder.frameEditing=")!==-1}const ue=()=>{if(c()){const e=new URL(location.href);return e.pathname===""&&(e.pathname="/"),e}else return console.warn("Cannot get location for tracking in non-browser environment"),null},de=()=>typeof navigator=="object"&&navigator.userAgent||"",N=()=>{const e=de(),t={Android(){return e.match(/Android/i)},BlackBerry(){return e.match(/BlackBerry/i)},iOS(){return e.match(/iPhone|iPod/i)},Opera(){return e.match(/Opera Mini/i)},Windows(){return e.match(/IEMobile/i)||e.match(/WPDesktop/i)},any(){return t.Android()||t.BlackBerry()||t.iOS()||t.Opera()||t.Windows()||I==="reactNative"}},n=e.match(/Tablet|iPad/i),r=ue();return{urlPath:r==null?void 0:r.pathname,host:(r==null?void 0:r.host)||(r==null?void 0:r.hostname),device:n?"tablet":t.any()?"mobile":"desktop"}},p=e=>e!=null;function le(e){const t=e||(c()?window.location.search:void 0);return t?U(t).indexOf("builder.preview=")!==-1:!1}const fe=e=>({type:"builder.registerComponent",data:k(e)}),ge=e=>{const t=e.toString().trim();return`return (${!t.startsWith("function")&&!t.startsWith("(")?"function ":""}${t}).apply(this, arguments)`};function k(e){return JSON.parse(JSON.stringify(e,(t,n)=>typeof n=="function"?ge(n):n))}const x={};function D(e,t){e==="plugin"&&(t=k(t));let n=x[e];if(n||(n=x[e]=[]),n.push(t),c()){const r={type:"builder.register",data:{type:e,info:t}};try{parent.postMessage(r,"*"),parent!==window&&window.postMessage(r,"*")}catch(o){console.debug("Could not postmessage",o)}}}const R={};function he(e){if(c()){Object.assign(R,e);const t={type:"builder.settingsChange",data:R};parent.postMessage(t,"*")}}const B="builder.",pe="options.",P=e=>{if(!e)return{};const t=M(e),n={};return Object.keys(t).forEach(r=>{if(r.startsWith(B)){const o=r.replace(B,"").replace(pe,"");n[o]=t[r]}}),n},me=()=>{if(!c())return{};const e=new URLSearchParams(window.location.search);return P(e)},ye=e=>{if(e==="localhost"||e==="127.0.0.1")return e;const t=e.split(".");return t.length>2?t.slice(1).join("."):e},j=({name:e,canTrack:t})=>{var n;try{return t?(n=document.cookie.split("; ").find(r=>r.startsWith(`${e}=`)))==null?void 0:n.split("=")[1]:void 0}catch(r){d.warn("[COOKIE] GET error: ",(r==null?void 0:r.message)||r);return}},K=async e=>j(e),Se=e=>e.map(([t,n])=>n?`${t}=${n}`:t).filter(p).join("; "),we=[["secure",""],["SameSite","None"]],be=({name:e,value:t,expires:n})=>{const o=(c()?location.protocol==="https:":!0)?we:[[]],s=n?[["expires",n.toUTCString()]]:[[]],a=[[e,t],...s,["path","/"],["domain",ye(window.location.hostname)],...o];return Se(a)},_=async({name:e,value:t,expires:n,canTrack:r})=>{try{if(!r)return;const o=be({name:e,value:t,expires:n});document.cookie=o}catch(o){d.warn("[COOKIE] SET error: ",(o==null?void 0:o.message)||o)}};function Ie(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e=="x"?t:t&3|8).toString(16)})}function W(){return Ie().replace(/-/g,"")}const $="builderSessionId",ve=async({canTrack:e})=>{if(!e)return;const t=await K({name:$,canTrack:e});if(p(t))return t;{const n=Ee();return ke({id:n,canTrack:e}),n}},Ee=()=>W(),ke=({id:e,canTrack:t})=>_({name:$,value:e,canTrack:t}),G=()=>c()&&typeof localStorage!="undefined"?localStorage:void 0,Pe=({key:e,canTrack:t})=>{var n;try{return t?(n=G())==null?void 0:n.getItem(e):void 0}catch(r){console.debug("[LocalStorage] GET error: ",r);return}},Ce=({key:e,canTrack:t,value:n})=>{var r;try{t&&((r=G())==null||r.setItem(e,n))}catch(o){console.debug("[LocalStorage] SET error: ",o)}},z="builderVisitorId",Oe=({canTrack:e})=>{if(!e)return;const t=Pe({key:z,canTrack:e});if(p(t))return t;{const n=Ae();return Te({id:n,canTrack:e}),n}},Ae=()=>W(),Te=({id:e,canTrack:t})=>Ce({key:z,value:e,canTrack:t}),xe=async({canTrack:e})=>{if(!e)return{visitorId:void 0,sessionId:void 0};const t=await ve({canTrack:e}),n=Oe({canTrack:e});return{sessionId:t,visitorId:n}},Re=async({type:e,canTrack:t,apiKey:n,metadata:r,...o})=>({type:e,data:{...o,metadata:{url:location.href,...r},...await xe({canTrack:t}),userAttributes:N(),ownerId:n}});async function J(e){if(!e.apiKey){d.error("Missing API key for track call. Please provide your API key.");return}if(e.canTrack&&!F()&&(c()||I==="reactNative"))return fetch("https://cdn.builder.io/api/v1/track",{method:"POST",body:JSON.stringify({events:[await Re(e)]}),headers:{"content-type":"application/json"},mode:"cors"}).catch(t=>{console.error("Failed to track: ",t)})}const Be=e=>J({...e,canTrack:!0}),Le=["*.beta.builder.io","beta.builder.io","builder.io","localhost","qa.builder.io"];function H(e,t){if(!t.origin.startsWith("http")&&!t.origin.startsWith("https"))return!1;const n=new URL(t.origin),r=n.hostname;return(e||Le).findIndex(o=>o.startsWith("*.")?r.endsWith(o.slice(1)):o===r)>-1}const Ve="2.0.24-0",Me=()=>{D("insertMenu",{name:"_default",default:!0,items:[{name:"Box"},{name:"Text"},{name:"Image"},{name:"Columns"},{name:"Core:Section"},{name:"Core:Button"},{name:"Embed"},{name:"Custom Code"}]})};let L=!1;const X=(e={})=>{var t,n;L||(L=!0,c()&&((t=window.parent)==null||t.postMessage({type:"builder.sdkInfo",data:{target:I,version:Ve,supportsPatchUpdates:!1,supportsAddBlockScoping:!0,supportsCustomBreakpoints:!0}},"*"),(n=window.parent)==null||n.postMessage({type:"builder.updateContent",data:{options:e}},"*"),window.addEventListener("message",r=>{var s,a;if(!H(e.trustedHosts,r))return;const{data:o}=r;if(o!=null&&o.type)switch(o.type){case"builder.evaluate":{const l=o.data.text,y=o.data.arguments||[],m=o.data.id,v=new Function(l);let u,g=null;try{u=v.apply(null,y)}catch(h){g=h}g?(s=window.parent)==null||s.postMessage({type:"builder.evaluateError",data:{id:m,error:g.message}},"*"):u&&typeof u.then=="function"?u.then(h=>{var S;(S=window.parent)==null||S.postMessage({type:"builder.evaluateResult",data:{id:m,result:h}},"*")}).catch(console.error):(a=window.parent)==null||a.postMessage({type:"builder.evaluateResult",data:{result:u,id:m}},"*");break}}})))},q=({model:e,trustedHosts:t,callbacks:n})=>r=>{if(!H(t,r))return;const{data:o}=r;if(o)switch(o.type){case"builder.configureSdk":{n.configureSdk(o.data);break}case"builder.triggerAnimation":{n.animation(o.data);break}case"builder.contentUpdate":{const s=o.data,a=s.key||s.alias||s.entry||s.modelName,l=s.data;a===e&&n.contentUpdate(l);break}}},Ue=(e,t,n)=>{if(!c)return d.warn("`subscribeToEditor` only works in the browser. It currently seems to be running on the server."),()=>{};X();const r=q({callbacks:{contentUpdate:t,animation:()=>{},configureSdk:()=>{}},model:e,trustedHosts:n==null?void 0:n.trustedHosts});return window.addEventListener("message",r),()=>{window.removeEventListener("message",r)}},Fe="builder.tests",C=e=>`${Fe}.${e}`,Ne=({contentId:e})=>K({name:C(e),canTrack:!0}),De=({contentId:e})=>j({name:C(e),canTrack:!0}),je=({contentId:e,value:t})=>_({name:C(e),value:t,canTrack:!0}),Q=e=>p(e.id)&&p(e.variations)&&Object.keys(e.variations).length>0,Ke=({id:e,variations:t})=>{var o;let n=0;const r=Math.random();for(const s in t){const a=(o=t[s])==null?void 0:o.testRatio;if(n+=a,r<n)return s}return e},Y=e=>{const t=Ke(e);return je({contentId:e.id,value:t}).catch(n=>{d.error("could not store A/B test variation: ",n)}),t},Z=({item:e,testGroupId:t})=>{const n=e.variations[t];return t===e.id||!n?{testVariationId:e.id,testVariationName:"Default"}:{data:n.data,testVariationId:n.id,testVariationName:n.name||(n.id===e.id?"Default":"")}},_e=({item:e,canTrack:t})=>{if(!t)return e;if(!e)return;if(!Q(e))return e;const n=De({contentId:e.id})||Y({variations:e.variations,id:e.id}),r=Z({item:e,testGroupId:n});return{...e,...r}},We=async({item:e,canTrack:t})=>{if(!t||!Q(e))return e;const r=await Ne({contentId:e.id})||Y({variations:e.variations,id:e.id}),o=Z({item:e,testGroupId:r});return{...e,...o}},ee=e=>p(e)?e:!0;function $e(){return typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:globalThis}function Ge(){const e=$e().fetch;if(typeof e=="undefined")throw console.warn(`Builder SDK could not find a global fetch function. Make sure you have a polyfill for fetch in your project.
|
|
2
2
|
For more information, read https://github.com/BuilderIO/this-package-uses-fetch`),new Error("Builder SDK could not find a global `fetch` function");return e}const ze=Ge();function E(e,t=null,n="."){return Object.keys(e).reduce((r,o)=>{const s=e[o],a=[t,o].filter(Boolean).join(n);return[typeof s=="object",s!==null,!(Array.isArray(s)&&s.length===0)].every(Boolean)?{...r,...E(s,a,n)}:{...r,[a]:s}},{})}function te(e,t,n={}){for(const r in e){const o=e[r],s=t?t+"."+r:r;o&&typeof o=="object"&&!Array.isArray(o)&&!Object.keys(o).find(a=>a.startsWith("$"))?te(o,s,n):n[s]=o}return n}const Je="v3",V=e=>typeof e=="number"&&!isNaN(e)&&e>=0,O=e=>{const{limit:t=30,userAttributes:n,query:r,model:o,apiKey:s,enrich:a,locale:l,apiVersion:y=Je,fields:m,omit:v,offset:u,cacheSeconds:g,staleCacheSeconds:h,sort:S,includeUnpublished:A}=e;if(!s)throw new Error("Missing API key");if(!["v3"].includes(y))throw new Error(`Invalid apiVersion: expected 'v3', received '${y}'`);const se=t!==1,i=new URL(`https://cdn.builder.io/api/${y}/content/${o}`);if(i.searchParams.set("apiKey",s),i.searchParams.set("limit",String(t)),i.searchParams.set("noTraverse",String(se)),i.searchParams.set("includeRefs",String(!0)),l&&i.searchParams.set("locale",l),a&&i.searchParams.set("enrich",String(a)),i.searchParams.set("omit",v||"meta.componentsUsed"),m&&i.searchParams.set("fields",m),Number.isFinite(u)&&u>-1&&i.searchParams.set("offset",String(Math.floor(u))),typeof A=="boolean"&&i.searchParams.set("includeUnpublished",String(A)),g&&V(g)&&i.searchParams.set("cacheSeconds",String(g)),h&&V(h)&&i.searchParams.set("staleCacheSeconds",String(h)),S){const f=E({sort:S});for(const w in f)i.searchParams.set(w,JSON.stringify(f[w]))}const ie={...me(),...M(e.options||{})},T=E(ie);for(const f in T)i.searchParams.set(f,String(T[f]));if(n&&i.searchParams.set("userAttributes",JSON.stringify(n)),r){const f=te({query:r});for(const w in f)i.searchParams.set(w,JSON.stringify(f[w]))}return i},He=e=>"results"in e;async function ne(e){const t=await oe({...e,limit:1});return t&&t[0]||null}const Xe=async e=>{var s;const t=O(e);return await(await((s=e.fetch)!=null?s:ze)(t.href,e.fetchOptions)).json()},re=async(e,t,n=O(e))=>{const r=ee(e.canTrack);if(n.search.includes("preview="),!r||!(c()||I==="reactNative"))return t.results;try{const o=[];for(const s of t.results)o.push(await We({item:s,canTrack:r}));t.results=o}catch(o){d.error("Could not process A/B tests. ",o)}return t.results};async function oe(e){try{const t=O(e),n=await Xe(e);return He(n)?re(e,n):(d.error("Error fetching data. ",{url:t,content:n,options:e}),null)}catch(t){return d.error("Error fetching data. ",t),null}}const qe=async e=>{var r,o,s;const t=e.path||((r=e.url)==null?void 0:r.pathname)||((o=e.userAttributes)==null?void 0:o.urlPath),n={...e,apiKey:e.apiKey,model:e.model||"page",userAttributes:{...e.userAttributes,...t?{urlPath:t}:{}},options:P(e.searchParams||((s=e.url)==null?void 0:s.searchParams)||e.options)};return{apiKey:n.apiKey,model:n.model,content:await ne(n)}};exports.MSG_PREFIX=b;exports.TARGET=I;exports._processContentResult=re;exports._track=J;exports.checkIsDefined=p;exports.createEditorListener=q;exports.createRegisterComponentMessage=fe;exports.fetchBuilderProps=qe;exports.fetchEntries=oe;exports.fetchOneEntry=ne;exports.getBuilderSearchParams=P;exports.getDefaultCanTrack=ee;exports.getUserAttributes=N;exports.handleABTestingSync=_e;exports.isBrowser=c;exports.isEditing=F;exports.isPreviewing=le;exports.logger=d;exports.register=D;exports.registerInsertMenu=Me;exports.serializeIncludingFunctions=k;exports.setEditorSettings=he;exports.setupBrowserForEditing=X;exports.subscribeToEditor=Ue;exports.track=Be;
|
|
@@ -302,7 +302,7 @@ function $(t, e) {
|
|
|
302
302
|
const n = new URL(e.origin), r = n.hostname;
|
|
303
303
|
return (t || kt).findIndex((o) => o.startsWith("*.") ? r.endsWith(o.slice(1)) : o === r) > -1;
|
|
304
304
|
}
|
|
305
|
-
const Et = "2.0.
|
|
305
|
+
const Et = "2.0.24-0", zt = () => {
|
|
306
306
|
ot("insertMenu", {
|
|
307
307
|
name: "_default",
|
|
308
308
|
default: !0,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./server-entry-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./server-entry-1c1c1459.cjs");exports._processContentResult=e._processContentResult;exports.createRegisterComponentMessage=e.createRegisterComponentMessage;exports.fetchBuilderProps=e.fetchBuilderProps;exports.fetchEntries=e.fetchEntries;exports.fetchOneEntry=e.fetchOneEntry;exports.getBuilderSearchParams=e.getBuilderSearchParams;exports.isEditing=e.isEditing;exports.isPreviewing=e.isPreviewing;exports.register=e.register;exports.setEditorSettings=e.setEditorSettings;exports.subscribeToEditor=e.subscribeToEditor;exports.track=e.track;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _processContentResult as r, createRegisterComponentMessage as s, fetchBuilderProps as i, fetchEntries as n, fetchOneEntry as o, getBuilderSearchParams as c, isEditing as g, isPreviewing as a, register as d, setEditorSettings as E, subscribeToEditor as f, track as h } from "./server-entry-
|
|
1
|
+
import { _processContentResult as r, createRegisterComponentMessage as s, fetchBuilderProps as i, fetchEntries as n, fetchOneEntry as o, getBuilderSearchParams as c, isEditing as g, isPreviewing as a, register as d, setEditorSettings as E, subscribeToEditor as f, track as h } from "./server-entry-8956b57e.js";
|
|
2
2
|
export {
|
|
3
3
|
r as _processContentResult,
|
|
4
4
|
s as createRegisterComponentMessage,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { isEditing, isBrowser, getUserAttributes, TARGET, logger, MSG_PREFIX
|
|
1
|
+
import { isEditing, isBrowser, getUserAttributes, TARGET, logger, MSG_PREFIX } from "./server-entry-8956b57e.js";
|
|
2
2
|
const getFunctionArguments = ({
|
|
3
3
|
builder: e,
|
|
4
4
|
context: t,
|
|
5
|
-
event:
|
|
5
|
+
event: s,
|
|
6
6
|
state: n
|
|
7
7
|
}) => Object.entries({
|
|
8
8
|
state: n,
|
|
@@ -10,7 +10,7 @@ const getFunctionArguments = ({
|
|
|
10
10
|
// legacy
|
|
11
11
|
builder: e,
|
|
12
12
|
context: t,
|
|
13
|
-
event:
|
|
13
|
+
event: s
|
|
14
14
|
}), getBuilderGlobals = () => ({
|
|
15
15
|
isEditing: isEditing(),
|
|
16
16
|
isBrowser: isBrowser(),
|
|
@@ -22,25 +22,25 @@ const getFunctionArguments = ({
|
|
|
22
22
|
function flattenState({
|
|
23
23
|
rootState: e,
|
|
24
24
|
localState: t,
|
|
25
|
-
rootSetState:
|
|
25
|
+
rootSetState: s
|
|
26
26
|
}) {
|
|
27
27
|
return new Proxy(e, {
|
|
28
|
-
get: (n,
|
|
29
|
-
if (t &&
|
|
30
|
-
return t[
|
|
31
|
-
const
|
|
32
|
-
return typeof
|
|
33
|
-
rootState:
|
|
28
|
+
get: (n, r) => {
|
|
29
|
+
if (t && r in t)
|
|
30
|
+
return t[r];
|
|
31
|
+
const o = n[r];
|
|
32
|
+
return typeof o == "object" && o !== null ? flattenState({
|
|
33
|
+
rootState: o,
|
|
34
34
|
localState: void 0,
|
|
35
|
-
rootSetState:
|
|
36
|
-
n[
|
|
35
|
+
rootSetState: s ? (i) => {
|
|
36
|
+
n[r] = i, s(n);
|
|
37
37
|
} : void 0
|
|
38
|
-
}) :
|
|
38
|
+
}) : o;
|
|
39
39
|
},
|
|
40
|
-
set: (n,
|
|
41
|
-
if (t &&
|
|
40
|
+
set: (n, r, o) => {
|
|
41
|
+
if (t && r in t)
|
|
42
42
|
throw new Error("Writing to local state is not allowed as it is read-only.");
|
|
43
|
-
return n[
|
|
43
|
+
return n[r] = o, s == null || s(n), !0;
|
|
44
44
|
}
|
|
45
45
|
});
|
|
46
46
|
}
|
|
@@ -53,11 +53,11 @@ const SDK_NAME_FOR_TARGET = (() => {
|
|
|
53
53
|
default:
|
|
54
54
|
return TARGET;
|
|
55
55
|
}
|
|
56
|
-
})(), SDK_NAME = `@builder.io/sdk-${SDK_NAME_FOR_TARGET}`, fastClone = (e) => JSON.parse(JSON.stringify(e)), set = (e, t,
|
|
56
|
+
})(), SDK_NAME = `@builder.io/sdk-${SDK_NAME_FOR_TARGET}`, fastClone = (e) => JSON.parse(JSON.stringify(e)), set = (e, t, s) => {
|
|
57
57
|
if (Object(e) !== e)
|
|
58
58
|
return e;
|
|
59
59
|
const n = Array.isArray(t) ? t : t.toString().match(/[^.[\]]+/g);
|
|
60
|
-
return n.slice(0, -1).reduce((
|
|
60
|
+
return n.slice(0, -1).reduce((r, o, i) => Object(r[o]) === r[o] ? r[o] : r[o] = Math.abs(Number(n[i + 1])) >> 0 === +n[i + 1] ? [] : {}, e)[n[n.length - 1]] = s, e;
|
|
61
61
|
}, noop = () => {
|
|
62
62
|
};
|
|
63
63
|
let safeDynamicRequire = noop;
|
|
@@ -95,10 +95,10 @@ var refToProxy = (obj) => {
|
|
|
95
95
|
code: e,
|
|
96
96
|
args: t
|
|
97
97
|
}) => {
|
|
98
|
-
const
|
|
98
|
+
const s = t.map(([n]) => `var ${n} = refToProxy(${getSyncValName(n)}); `).join("");
|
|
99
99
|
return `
|
|
100
100
|
${REF_TO_PROXY_FN}
|
|
101
|
-
${
|
|
101
|
+
${s}
|
|
102
102
|
function theFunction() {
|
|
103
103
|
${e}
|
|
104
104
|
}
|
|
@@ -138,64 +138,51 @@ const setIvm = (e, t = {}) => {
|
|
|
138
138
|
function setIsolateContext(e = {
|
|
139
139
|
memoryLimit: 128
|
|
140
140
|
}) {
|
|
141
|
-
const t = getIvm(), n = new t.Isolate(e).createContextSync(),
|
|
142
|
-
return
|
|
143
|
-
console.log(...
|
|
144
|
-
}),
|
|
141
|
+
const t = getIvm(), n = new t.Isolate(e).createContextSync(), r = n.global;
|
|
142
|
+
return r.setSync("global", r.derefInto()), r.setSync("log", function(...o) {
|
|
143
|
+
console.log(...o);
|
|
144
|
+
}), r.setSync(INJECTED_IVM_GLOBAL, t), IVM_CONTEXT = n, n;
|
|
145
145
|
}
|
|
146
146
|
const getIsolateContext = () => IVM_CONTEXT || setIsolateContext(), runInNode = ({
|
|
147
147
|
code: e,
|
|
148
148
|
builder: t,
|
|
149
|
-
context:
|
|
149
|
+
context: s,
|
|
150
150
|
event: n,
|
|
151
|
-
localState:
|
|
152
|
-
rootSetState:
|
|
151
|
+
localState: r,
|
|
152
|
+
rootSetState: o,
|
|
153
153
|
rootState: i
|
|
154
154
|
}) => {
|
|
155
|
-
const
|
|
155
|
+
const I = getIvm(), _ = fastClone({
|
|
156
156
|
...i,
|
|
157
|
-
...
|
|
157
|
+
...r
|
|
158
158
|
}), l = getFunctionArguments({
|
|
159
159
|
builder: t,
|
|
160
|
-
context:
|
|
160
|
+
context: s,
|
|
161
161
|
event: n,
|
|
162
|
-
state:
|
|
163
|
-
}), a = getIsolateContext(),
|
|
164
|
-
|
|
165
|
-
set(i, c, u),
|
|
162
|
+
state: _
|
|
163
|
+
}), a = getIsolateContext(), E = a.global;
|
|
164
|
+
E.setSync(BUILDER_SET_STATE_NAME, function(c, u) {
|
|
165
|
+
set(i, c, u), o == null || o(i);
|
|
166
166
|
}), l.forEach(([c, u]) => {
|
|
167
|
-
const
|
|
167
|
+
const f = typeof u == "object" ? new I.Reference(
|
|
168
168
|
// workaround: methods with default values for arguments is not being cloned over
|
|
169
169
|
c === "builder" ? {
|
|
170
170
|
...u,
|
|
171
171
|
getUserAttributes: () => u.getUserAttributes()
|
|
172
172
|
} : u
|
|
173
173
|
) : null;
|
|
174
|
-
|
|
174
|
+
E.setSync(getSyncValName(c), f);
|
|
175
175
|
});
|
|
176
|
-
const
|
|
176
|
+
const d = processCode({
|
|
177
177
|
code: e,
|
|
178
178
|
args: l
|
|
179
|
-
}),
|
|
179
|
+
}), y = a.evalClosureSync(d);
|
|
180
180
|
try {
|
|
181
|
-
return JSON.parse(
|
|
181
|
+
return JSON.parse(y);
|
|
182
182
|
} catch {
|
|
183
|
-
return
|
|
183
|
+
return y;
|
|
184
184
|
}
|
|
185
185
|
};
|
|
186
|
-
function isNodeRuntime() {
|
|
187
|
-
var e;
|
|
188
|
-
return typeof process != "undefined" && checkIsDefined((e = process == null ? void 0 : process.versions) == null ? void 0 : e.node);
|
|
189
|
-
}
|
|
190
|
-
const shouldForceBrowserRuntimeInNode = ({
|
|
191
|
-
shouldLogWarning: e
|
|
192
|
-
}) => {
|
|
193
|
-
var o;
|
|
194
|
-
if (!isNodeRuntime())
|
|
195
|
-
return !1;
|
|
196
|
-
const t = process.arch === "arm64", r = process.version.startsWith("v20"), n = (o = process.env.NODE_OPTIONS) == null ? void 0 : o.includes("--no-node-snapshot");
|
|
197
|
-
return t && r && !n ? (e && logger.log("Skipping usage of `isolated-vm` to avoid crashes in Node v20 on an arm64 machine.\n If you would like to use the `isolated-vm` package on this machine, please provide the `NODE_OPTIONS=--no-node-snapshot` config to your Node process.\n See https://github.com/BuilderIO/builder/blob/main/packages/sdks/README.md#node-v20--m1-macs-apple-silicon-support for more information.\n "), !0) : !1;
|
|
198
|
-
};
|
|
199
186
|
export {
|
|
200
187
|
fastClone,
|
|
201
188
|
flattenState,
|
|
@@ -204,6 +191,5 @@ export {
|
|
|
204
191
|
parseCode,
|
|
205
192
|
runInNode,
|
|
206
193
|
set,
|
|
207
|
-
setIvm
|
|
208
|
-
shouldForceBrowserRuntimeInNode
|
|
194
|
+
setIvm
|
|
209
195
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const serverEntry=require("./server-entry-
|
|
1
|
+
"use strict";const serverEntry=require("./server-entry-1c1c1459.cjs"),getFunctionArguments=({builder:e,context:t,event:s,state:n})=>Object.entries({state:n,Builder:e,builder:e,context:t,event:s}),getBuilderGlobals=()=>({isEditing:serverEntry.isEditing(),isBrowser:serverEntry.isBrowser(),isServer:!serverEntry.isBrowser(),getUserAttributes:()=>serverEntry.getUserAttributes()}),parseCode=(e,{isExpression:t=!0})=>t&&!(e.includes(";")||e.includes(" return ")||e.trim().startsWith("return "))?`return (${e});`:e;function flattenState({rootState:e,localState:t,rootSetState:s}){return new Proxy(e,{get:(n,r)=>{if(t&&r in t)return t[r];const o=n[r];return typeof o=="object"&&o!==null?flattenState({rootState:o,localState:void 0,rootSetState:s?i=>{n[r]=i,s(n)}:void 0}):o},set:(n,r,o)=>{if(t&&r in t)throw new Error("Writing to local state is not allowed as it is read-only.");return n[r]=o,s==null||s(n),!0}})}const SDK_NAME_FOR_TARGET=(()=>{switch(serverEntry.TARGET){case"rsc":return"react-nextjs";case"reactNative":return"react-native";default:return serverEntry.TARGET}})(),SDK_NAME=`@builder.io/sdk-${SDK_NAME_FOR_TARGET}`,fastClone=e=>JSON.parse(JSON.stringify(e)),set=(e,t,s)=>{if(Object(e)!==e)return e;const n=Array.isArray(t)?t:t.toString().match(/[^.[\]]+/g);return n.slice(0,-1).reduce((r,o,i)=>Object(r[o])===r[o]?r[o]:r[o]=Math.abs(Number(n[i+1]))>>0===+n[i+1]?[]:{},e)[n[n.length-1]]=s,e},noop=()=>{};let safeDynamicRequire=noop;try{safeDynamicRequire=eval("require")}catch(e){}const getSyncValName=e=>`bldr_${e}_sync`,BUILDER_SET_STATE_NAME="BUILDER_SET_STATE",INJECTED_IVM_GLOBAL="BUILDER_IVM",REF_TO_PROXY_FN=`
|
|
2
2
|
var refToProxy = (obj) => {
|
|
3
3
|
if (typeof obj !== 'object' || obj === null) {
|
|
4
4
|
return obj;
|
|
@@ -24,9 +24,9 @@ var refToProxy = (obj) => {
|
|
|
24
24
|
}
|
|
25
25
|
})
|
|
26
26
|
}
|
|
27
|
-
`,processCode=({code:e,args:t})=>{const
|
|
27
|
+
`,processCode=({code:e,args:t})=>{const s=t.map(([n])=>`var ${n} = refToProxy(${getSyncValName(n)}); `).join("");return`
|
|
28
28
|
${REF_TO_PROXY_FN}
|
|
29
|
-
${
|
|
29
|
+
${s}
|
|
30
30
|
function theFunction() {
|
|
31
31
|
${e}
|
|
32
32
|
}
|
|
@@ -45,4 +45,4 @@ if (typeof output === 'object' && output !== null) {
|
|
|
45
45
|
${SHOULD_MENTION_INITIALIZE_SCRIPT?`- import and call \`initializeNodeRuntime()\` from "${SDK_NAME}/node/init".`:""}
|
|
46
46
|
- add the following import: \`await import('isolated-vm')\`.
|
|
47
47
|
|
|
48
|
-
For more information, visit https://builder.io/c/docs/integration-tips#enabling-data-bindings-in-node-environments`;throw new Error(e)};function setIsolateContext(e={memoryLimit:128}){const t=getIvm(),n=new t.Isolate(e).createContextSync(),r=n.global;return r.setSync("global",r.derefInto()),r.setSync("log",function(...
|
|
48
|
+
For more information, visit https://builder.io/c/docs/integration-tips#enabling-data-bindings-in-node-environments`;throw new Error(e)};function setIsolateContext(e={memoryLimit:128}){const t=getIvm(),n=new t.Isolate(e).createContextSync(),r=n.global;return r.setSync("global",r.derefInto()),r.setSync("log",function(...o){console.log(...o)}),r.setSync(INJECTED_IVM_GLOBAL,t),IVM_CONTEXT=n,n}const getIsolateContext=()=>IVM_CONTEXT||setIsolateContext(),runInNode=({code:e,builder:t,context:s,event:n,localState:r,rootSetState:o,rootState:i})=>{const I=getIvm(),d=fastClone({...i,...r}),l=getFunctionArguments({builder:t,context:s,event:n,state:d}),a=getIsolateContext(),y=a.global;y.setSync(BUILDER_SET_STATE_NAME,function(c,u){set(i,c,u),o==null||o(i)}),l.forEach(([c,u])=>{const f=typeof u=="object"?new I.Reference(c==="builder"?{...u,getUserAttributes:()=>u.getUserAttributes()}:u):null;y.setSync(getSyncValName(c),f)});const _=processCode({code:e,args:l}),E=a.evalClosureSync(_);try{return JSON.parse(E)}catch{return E}};exports.fastClone=fastClone;exports.flattenState=flattenState;exports.getBuilderGlobals=getBuilderGlobals;exports.getFunctionArguments=getFunctionArguments;exports.parseCode=parseCode;exports.runInNode=runInNode;exports.set=set;exports.setIvm=setIvm;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./setIvm-bf4f998d.cjs");require("./server-entry-1c1c1459.cjs");exports.setIvm=e.setIvm;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { checkIsDefined as i, logger as t } from "./server-entry-8956b57e.js";
|
|
2
|
+
function a() {
|
|
3
|
+
var o;
|
|
4
|
+
return typeof process != "undefined" && i((o = process == null ? void 0 : process.versions) == null ? void 0 : o.node);
|
|
5
|
+
}
|
|
6
|
+
const d = ({
|
|
7
|
+
shouldLogWarning: o
|
|
8
|
+
}) => {
|
|
9
|
+
var e;
|
|
10
|
+
if (!a())
|
|
11
|
+
return !1;
|
|
12
|
+
const s = process.arch === "arm64", n = process.version.startsWith("v20"), r = (e = process.env.NODE_OPTIONS) == null ? void 0 : e.includes("--no-node-snapshot");
|
|
13
|
+
return s && n && !r ? (o && t.log("Skipping usage of `isolated-vm` to avoid crashes in Node v20 on an arm64 machine.\n If you would like to use the `isolated-vm` package on this machine, please provide the `NODE_OPTIONS=--no-node-snapshot` config to your Node process.\n See https://github.com/BuilderIO/builder/blob/main/packages/sdks/README.md#node-v20--m1-macs-apple-silicon-support for more information.\n "), !0) : !1;
|
|
14
|
+
};
|
|
15
|
+
export {
|
|
16
|
+
d as shouldForceBrowserRuntimeInNode
|
|
17
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const s=require("./server-entry-1c1c1459.cjs");function t(){var e;return typeof process!="undefined"&&s.checkIsDefined((e=process==null?void 0:process.versions)==null?void 0:e.node)}const c=({shouldLogWarning:e})=>{var o;if(!t())return!1;const n=process.arch==="arm64",r=process.version.startsWith("v20"),i=(o=process.env.NODE_OPTIONS)==null?void 0:o.includes("--no-node-snapshot");return n&&r&&!i?(e&&s.logger.log("Skipping usage of `isolated-vm` to avoid crashes in Node v20 on an arm64 machine.\n If you would like to use the `isolated-vm` package on this machine, please provide the `NODE_OPTIONS=--no-node-snapshot` config to your Node process.\n See https://github.com/BuilderIO/builder/blob/main/packages/sdks/README.md#node-v20--m1-macs-apple-silicon-support for more information.\n "),!0):!1};exports.shouldForceBrowserRuntimeInNode=c;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@builder.io/sdk-react",
|
|
3
3
|
"description": "Builder.io SDK for React",
|
|
4
|
-
"version": "2.0.24-
|
|
4
|
+
"version": "2.0.24-2",
|
|
5
5
|
"homepage": "https://github.com/BuilderIO/builder/tree/main/packages/sdks/output/react",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"repository": {
|
|
@@ -85,6 +85,11 @@
|
|
|
85
85
|
"import": "./lib/node/init.mjs",
|
|
86
86
|
"require": "./lib/node/init.cjs"
|
|
87
87
|
},
|
|
88
|
+
"./node/setIvm": {
|
|
89
|
+
"types": "./types/functions/evaluate/node-runtime/setIvm.d.ts",
|
|
90
|
+
"import": "./lib/node/setIvm.mjs",
|
|
91
|
+
"require": "./lib/node/setIvm.cjs"
|
|
92
|
+
},
|
|
88
93
|
"./edge": {
|
|
89
94
|
"types": "./types/index.d.ts",
|
|
90
95
|
"import": "./lib/edge/edge-entry.mjs",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "2.0.
|
|
1
|
+
export declare const SDK_VERSION = "2.0.24-0";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { setIvm } from './node-runtime';
|