@weaverse/core 0.7.12 → 0.7.13
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/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/dist/index.mjs +2 -2
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -303,7 +303,7 @@ declare class Weaverse {
|
|
|
303
303
|
unsubscribe(fn: any): void;
|
|
304
304
|
triggerUpdate(): void;
|
|
305
305
|
/**
|
|
306
|
-
* fetch data from Weaverse API (https://weaverse.io/api/v1/
|
|
306
|
+
* fetch data from Weaverse API (https://weaverse.io/api/v1/project/:projectKey)
|
|
307
307
|
* @param fetch {fetch} custom fetch function, pass in custom fetch function if you want to use your own fetch function
|
|
308
308
|
* @param appUrl
|
|
309
309
|
* @param projectKey
|
package/dist/index.js
CHANGED
|
@@ -151,7 +151,7 @@ var Weaverse = class {
|
|
|
151
151
|
constructor({ appUrl, projectKey, projectData, mediaBreakPoints, isDesignMode, ssrMode } = {}) {
|
|
152
152
|
this.elementInstances = /* @__PURE__ */ new Map();
|
|
153
153
|
this.itemInstances = /* @__PURE__ */ new Map();
|
|
154
|
-
this.appUrl = process.env.NODE_ENV === "development" ? "http://localhost:3000" : "https://
|
|
154
|
+
this.appUrl = process.env.NODE_ENV === "development" ? "http://localhost:3000" : "https://studio.weaverse.io";
|
|
155
155
|
this.projectKey = "";
|
|
156
156
|
this.projectData = {
|
|
157
157
|
rootId: "",
|
|
@@ -243,7 +243,7 @@ var Weaverse = class {
|
|
|
243
243
|
appUrl,
|
|
244
244
|
projectKey
|
|
245
245
|
}) {
|
|
246
|
-
return fetch(appUrl + `/api/public/${projectKey}`).then((r) => r.json()).catch(console.error);
|
|
246
|
+
return fetch(appUrl + `/api/public/project/${projectKey}`).then((r) => r.json()).catch(console.error);
|
|
247
247
|
}
|
|
248
248
|
setProjectData(projectData) {
|
|
249
249
|
this.projectData = projectData;
|
package/dist/index.mjs
CHANGED
|
@@ -113,7 +113,7 @@ var Weaverse = class {
|
|
|
113
113
|
constructor({ appUrl, projectKey, projectData, mediaBreakPoints, isDesignMode, ssrMode } = {}) {
|
|
114
114
|
this.elementInstances = /* @__PURE__ */ new Map();
|
|
115
115
|
this.itemInstances = /* @__PURE__ */ new Map();
|
|
116
|
-
this.appUrl = process.env.NODE_ENV === "development" ? "http://localhost:3000" : "https://
|
|
116
|
+
this.appUrl = process.env.NODE_ENV === "development" ? "http://localhost:3000" : "https://studio.weaverse.io";
|
|
117
117
|
this.projectKey = "";
|
|
118
118
|
this.projectData = {
|
|
119
119
|
rootId: "",
|
|
@@ -205,7 +205,7 @@ var Weaverse = class {
|
|
|
205
205
|
appUrl,
|
|
206
206
|
projectKey
|
|
207
207
|
}) {
|
|
208
|
-
return fetch(appUrl + `/api/public/${projectKey}`).then((r) => r.json()).catch(console.error);
|
|
208
|
+
return fetch(appUrl + `/api/public/project/${projectKey}`).then((r) => r.json()).catch(console.error);
|
|
209
209
|
}
|
|
210
210
|
setProjectData(projectData) {
|
|
211
211
|
this.projectData = projectData;
|
package/package.json
CHANGED