@getforma/core 0.9.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +20 -1
- package/dist/chunk-DCTOXHPF.cjs +399 -0
- package/dist/chunk-DCTOXHPF.cjs.map +1 -0
- package/dist/chunk-OUVOAYIO.js +359 -0
- package/dist/chunk-OUVOAYIO.js.map +1 -0
- package/dist/{chunk-YMIMKO4W.cjs → chunk-V732ZBCU.cjs} +119 -511
- package/dist/chunk-V732ZBCU.cjs.map +1 -0
- package/dist/{chunk-N522P3G6.js → chunk-VTPFK5TJ.js} +89 -442
- package/dist/chunk-VTPFK5TJ.js.map +1 -0
- package/dist/forma-runtime-csp.js +1 -1
- package/dist/forma-runtime.js +1 -1
- package/dist/formajs-runtime-hardened.global.js +1 -1
- package/dist/formajs-runtime-hardened.global.js.map +1 -1
- package/dist/formajs-runtime.global.js +1 -1
- package/dist/formajs-runtime.global.js.map +1 -1
- package/dist/formajs.global.js +1 -1
- package/dist/formajs.global.js.map +1 -1
- package/dist/http.cjs +225 -0
- package/dist/http.cjs.map +1 -0
- package/dist/http.d.cts +108 -0
- package/dist/http.d.ts +108 -0
- package/dist/http.js +220 -0
- package/dist/http.js.map +1 -0
- package/dist/index.cjs +71 -607
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -458
- package/dist/index.d.ts +4 -458
- package/dist/index.js +7 -523
- package/dist/index.js.map +1 -1
- package/dist/resource-Cd0cGOxS.d.ts +62 -0
- package/dist/resource-DK98lW5e.d.cts +62 -0
- package/dist/runtime-hardened.cjs +3 -111
- package/dist/runtime-hardened.cjs.map +1 -1
- package/dist/runtime-hardened.js +4 -112
- package/dist/runtime-hardened.js.map +1 -1
- package/dist/runtime.cjs +23 -22
- package/dist/runtime.cjs.map +1 -1
- package/dist/runtime.js +2 -1
- package/dist/runtime.js.map +1 -1
- package/dist/server.cjs +179 -0
- package/dist/server.cjs.map +1 -0
- package/dist/server.d.cts +217 -0
- package/dist/server.d.ts +217 -0
- package/dist/server.js +166 -0
- package/dist/server.js.map +1 -0
- package/dist/{signal-B4_wQJHs.d.cts → signal-YlS1kgfh.d.cts} +1 -1
- package/dist/{signal-B4_wQJHs.d.ts → signal-YlS1kgfh.d.ts} +1 -1
- package/dist/storage.cjs +151 -0
- package/dist/storage.cjs.map +1 -0
- package/dist/storage.d.cts +77 -0
- package/dist/storage.d.ts +77 -0
- package/dist/storage.js +147 -0
- package/dist/storage.js.map +1 -0
- package/dist/tc39-compat.d.cts +1 -1
- package/dist/tc39-compat.d.ts +1 -1
- package/package.json +31 -1
- package/dist/chunk-N522P3G6.js.map +0 -1
- package/dist/chunk-YMIMKO4W.cjs.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkV732ZBCU_cjs = require('./chunk-V732ZBCU.cjs');
|
|
4
|
+
var chunkDCTOXHPF_cjs = require('./chunk-DCTOXHPF.cjs');
|
|
4
5
|
var chunk3U57L2TY_cjs = require('./chunk-3U57L2TY.cjs');
|
|
5
6
|
|
|
6
7
|
// src/dom/text.ts
|
|
7
8
|
function createText(value) {
|
|
8
9
|
if (typeof value === "function") {
|
|
9
10
|
const node = new Text("");
|
|
10
|
-
|
|
11
|
+
chunkDCTOXHPF_cjs.internalEffect(() => {
|
|
11
12
|
node.data = value();
|
|
12
13
|
});
|
|
13
14
|
return node;
|
|
@@ -23,12 +24,12 @@ function mount(component, container) {
|
|
|
23
24
|
}
|
|
24
25
|
let disposeRoot;
|
|
25
26
|
if (target.hasAttribute("data-forma-ssr")) {
|
|
26
|
-
|
|
27
|
+
chunkDCTOXHPF_cjs.createRoot((dispose) => {
|
|
27
28
|
disposeRoot = dispose;
|
|
28
|
-
|
|
29
|
+
chunkV732ZBCU_cjs.hydrateIsland(component, target);
|
|
29
30
|
});
|
|
30
31
|
} else {
|
|
31
|
-
const dom =
|
|
32
|
+
const dom = chunkDCTOXHPF_cjs.createRoot((dispose) => {
|
|
32
33
|
disposeRoot = dispose;
|
|
33
34
|
return component();
|
|
34
35
|
});
|
|
@@ -54,7 +55,7 @@ function createSwitch(value, cases, fallback) {
|
|
|
54
55
|
const cache = /* @__PURE__ */ new Map();
|
|
55
56
|
let currentNode = null;
|
|
56
57
|
let currentMatch = UNSET;
|
|
57
|
-
const switchDispose =
|
|
58
|
+
const switchDispose = chunkDCTOXHPF_cjs.internalEffect(() => {
|
|
58
59
|
const val = value();
|
|
59
60
|
if (val === currentMatch) return;
|
|
60
61
|
const DEBUG = typeof globalThis.__FORMA_DEBUG__ !== "undefined";
|
|
@@ -89,9 +90,9 @@ function createSwitch(value, cases, fallback) {
|
|
|
89
90
|
let entry = cache.get(val);
|
|
90
91
|
if (!entry) {
|
|
91
92
|
let branchDispose;
|
|
92
|
-
const node =
|
|
93
|
+
const node = chunkDCTOXHPF_cjs.createRoot((dispose) => {
|
|
93
94
|
branchDispose = dispose;
|
|
94
|
-
return
|
|
95
|
+
return chunkDCTOXHPF_cjs.untrack(() => matchedCase.render());
|
|
95
96
|
});
|
|
96
97
|
entry = { node, dispose: branchDispose };
|
|
97
98
|
cache.set(val, entry);
|
|
@@ -134,7 +135,7 @@ function createPortal(children2, target) {
|
|
|
134
135
|
}
|
|
135
136
|
mountedNode = null;
|
|
136
137
|
};
|
|
137
|
-
|
|
138
|
+
chunkDCTOXHPF_cjs.createEffect(() => {
|
|
138
139
|
const node = children2();
|
|
139
140
|
removeMountedNode();
|
|
140
141
|
mountedNode = node;
|
|
@@ -155,7 +156,7 @@ function createErrorBoundary(tryFn, catchFn) {
|
|
|
155
156
|
fragment2.appendChild(endMarker);
|
|
156
157
|
const [retryCount, setRetryCount] = chunk3U57L2TY_cjs.createSignal(0);
|
|
157
158
|
let currentNode = null;
|
|
158
|
-
|
|
159
|
+
chunkDCTOXHPF_cjs.internalEffect(() => {
|
|
159
160
|
retryCount();
|
|
160
161
|
const parent2 = startMarker.parentNode;
|
|
161
162
|
if (!parent2) return;
|
|
@@ -195,13 +196,13 @@ function createSuspense(fallback, children2) {
|
|
|
195
196
|
setPending((p) => Math.max(0, p - 1));
|
|
196
197
|
}
|
|
197
198
|
};
|
|
198
|
-
|
|
199
|
+
chunkDCTOXHPF_cjs.pushSuspenseContext(ctx);
|
|
199
200
|
try {
|
|
200
201
|
resolvedNode = children2();
|
|
201
202
|
} finally {
|
|
202
|
-
|
|
203
|
+
chunkDCTOXHPF_cjs.popSuspenseContext();
|
|
203
204
|
}
|
|
204
|
-
|
|
205
|
+
chunkDCTOXHPF_cjs.internalEffect(() => {
|
|
205
206
|
const parent2 = startMarker.parentNode;
|
|
206
207
|
if (!parent2) return;
|
|
207
208
|
const isPending = pending() > 0;
|
|
@@ -236,16 +237,16 @@ function loadIslandProps(root, id, sharedProps) {
|
|
|
236
237
|
}
|
|
237
238
|
return null;
|
|
238
239
|
}
|
|
239
|
-
function activateIslands(
|
|
240
|
+
function activateIslands(registry) {
|
|
240
241
|
const scriptBlock = document.getElementById("__forma_islands");
|
|
241
242
|
const sharedProps = scriptBlock ? JSON.parse(scriptBlock.textContent) : null;
|
|
242
243
|
const islands = document.querySelectorAll("[data-forma-island]");
|
|
243
244
|
for (const root of islands) {
|
|
244
245
|
const id = parseInt(root.getAttribute("data-forma-island"), 10);
|
|
245
246
|
const componentName = root.getAttribute("data-forma-component");
|
|
246
|
-
const hydrateFn =
|
|
247
|
+
const hydrateFn = registry[componentName];
|
|
247
248
|
if (!hydrateFn) {
|
|
248
|
-
if (
|
|
249
|
+
if (chunkDCTOXHPF_cjs.__DEV__) console.warn(`[forma] No hydrate function for island "${componentName}" (id=${id})`);
|
|
249
250
|
root.setAttribute("data-forma-status", "error");
|
|
250
251
|
continue;
|
|
251
252
|
}
|
|
@@ -301,13 +302,13 @@ function hydrateIslandRoot(root, id, componentName, hydrateFn, sharedProps) {
|
|
|
301
302
|
const props = loadIslandProps(root, id, sharedProps);
|
|
302
303
|
root.setAttribute("data-forma-status", "hydrating");
|
|
303
304
|
let activeRoot = root;
|
|
304
|
-
|
|
305
|
-
activeRoot =
|
|
305
|
+
chunkDCTOXHPF_cjs.createRoot((dispose) => {
|
|
306
|
+
activeRoot = chunkV732ZBCU_cjs.hydrateIsland(() => hydrateFn(root, props), root);
|
|
306
307
|
activeRoot.__formaDispose = dispose;
|
|
307
308
|
});
|
|
308
309
|
activeRoot.setAttribute("data-forma-status", "active");
|
|
309
310
|
} catch (err) {
|
|
310
|
-
if (
|
|
311
|
+
if (chunkDCTOXHPF_cjs.__DEV__) console.error(`[forma] Island "${componentName}" (id=${id}) failed:`, err);
|
|
311
312
|
root.setAttribute("data-forma-status", "error");
|
|
312
313
|
}
|
|
313
314
|
}
|
|
@@ -356,14 +357,14 @@ function defineComponent(setupOrDef) {
|
|
|
356
357
|
try {
|
|
357
358
|
cb();
|
|
358
359
|
} catch (e) {
|
|
359
|
-
|
|
360
|
+
chunkDCTOXHPF_cjs.reportError(e, "onUnmount");
|
|
360
361
|
}
|
|
361
362
|
}
|
|
362
363
|
for (const d of ctx.disposers) {
|
|
363
364
|
try {
|
|
364
365
|
d();
|
|
365
366
|
} catch (e) {
|
|
366
|
-
|
|
367
|
+
chunkDCTOXHPF_cjs.reportError(e, "component disposer");
|
|
367
368
|
}
|
|
368
369
|
}
|
|
369
370
|
ctx.disposers.length = 0;
|
|
@@ -378,7 +379,7 @@ function defineComponent(setupOrDef) {
|
|
|
378
379
|
ctx.unmountCallbacks.push(cleanup2);
|
|
379
380
|
}
|
|
380
381
|
} catch (e) {
|
|
381
|
-
|
|
382
|
+
chunkDCTOXHPF_cjs.reportError(e, "onMount");
|
|
382
383
|
}
|
|
383
384
|
}
|
|
384
385
|
return dom;
|
|
@@ -521,7 +522,7 @@ function createStore(initial) {
|
|
|
521
522
|
if (isArr && ARRAY_MUTATORS.has(key)) {
|
|
522
523
|
return (...args) => {
|
|
523
524
|
let result;
|
|
524
|
-
|
|
525
|
+
chunkDCTOXHPF_cjs.batch(() => {
|
|
525
526
|
const rawArgs = args.map(
|
|
526
527
|
(a) => a != null && typeof a === "object" && a[RAW] ? a[RAW] : a
|
|
527
528
|
);
|
|
@@ -635,11 +636,11 @@ function createStore(initial) {
|
|
|
635
636
|
}
|
|
636
637
|
const rootProxy = wrap(initial, "");
|
|
637
638
|
function getCurrentSnapshot() {
|
|
638
|
-
return
|
|
639
|
+
return chunkDCTOXHPF_cjs.untrack(() => deepClone(initial));
|
|
639
640
|
}
|
|
640
641
|
const setter = (partial) => {
|
|
641
642
|
const updates = typeof partial === "function" ? partial(getCurrentSnapshot()) : partial;
|
|
642
|
-
|
|
643
|
+
chunkDCTOXHPF_cjs.batch(() => {
|
|
643
644
|
for (const key of Object.keys(updates)) {
|
|
644
645
|
rootProxy[key] = updates[key];
|
|
645
646
|
}
|
|
@@ -658,7 +659,7 @@ function createHistory(source, options) {
|
|
|
658
659
|
const [cursorSignal, setCursorSignal] = chunk3U57L2TY_cjs.createSignal(_cursor);
|
|
659
660
|
const [stackLenSignal, setStackLenSignal] = chunk3U57L2TY_cjs.createSignal(_stack.length);
|
|
660
661
|
function syncSignals() {
|
|
661
|
-
|
|
662
|
+
chunkDCTOXHPF_cjs.batch(() => {
|
|
662
663
|
setStackSignal([..._stack]);
|
|
663
664
|
setCursorSignal(_cursor);
|
|
664
665
|
setStackLenSignal(_stack.length);
|
|
@@ -666,7 +667,7 @@ function createHistory(source, options) {
|
|
|
666
667
|
}
|
|
667
668
|
let ignoreNext = false;
|
|
668
669
|
let isFirstRun = true;
|
|
669
|
-
|
|
670
|
+
chunkDCTOXHPF_cjs.internalEffect(() => {
|
|
670
671
|
const value = sourceGet();
|
|
671
672
|
if (isFirstRun) {
|
|
672
673
|
isFirstRun = false;
|
|
@@ -734,7 +735,7 @@ function persist(source, key, options) {
|
|
|
734
735
|
}
|
|
735
736
|
} catch {
|
|
736
737
|
}
|
|
737
|
-
|
|
738
|
+
chunkDCTOXHPF_cjs.internalEffect(() => {
|
|
738
739
|
const value = sourceGet();
|
|
739
740
|
try {
|
|
740
741
|
const serialized = serialize(value);
|
|
@@ -993,623 +994,105 @@ function onMutation(el, handler, options) {
|
|
|
993
994
|
};
|
|
994
995
|
}
|
|
995
996
|
|
|
996
|
-
// src/storage/local.ts
|
|
997
|
-
function createLocalStorage(key, options) {
|
|
998
|
-
const serialize = options?.serialize ?? JSON.stringify;
|
|
999
|
-
const deserialize = options?.deserialize ?? JSON.parse;
|
|
1000
|
-
const validate = options?.validate;
|
|
1001
|
-
return {
|
|
1002
|
-
key,
|
|
1003
|
-
get() {
|
|
1004
|
-
try {
|
|
1005
|
-
const raw = localStorage.getItem(key);
|
|
1006
|
-
if (raw === null) return null;
|
|
1007
|
-
const value = deserialize(raw);
|
|
1008
|
-
if (validate && !validate(value)) return null;
|
|
1009
|
-
return value;
|
|
1010
|
-
} catch {
|
|
1011
|
-
return null;
|
|
1012
|
-
}
|
|
1013
|
-
},
|
|
1014
|
-
set(value) {
|
|
1015
|
-
try {
|
|
1016
|
-
const serialized = serialize(value);
|
|
1017
|
-
localStorage.setItem(key, serialized);
|
|
1018
|
-
} catch {
|
|
1019
|
-
}
|
|
1020
|
-
},
|
|
1021
|
-
remove() {
|
|
1022
|
-
localStorage.removeItem(key);
|
|
1023
|
-
}
|
|
1024
|
-
};
|
|
1025
|
-
}
|
|
1026
|
-
|
|
1027
|
-
// src/storage/session.ts
|
|
1028
|
-
function createSessionStorage(key, options) {
|
|
1029
|
-
const serialize = options?.serialize ?? JSON.stringify;
|
|
1030
|
-
const deserialize = options?.deserialize ?? JSON.parse;
|
|
1031
|
-
const validate = options?.validate;
|
|
1032
|
-
return {
|
|
1033
|
-
key,
|
|
1034
|
-
get() {
|
|
1035
|
-
try {
|
|
1036
|
-
const raw = sessionStorage.getItem(key);
|
|
1037
|
-
if (raw === null) return null;
|
|
1038
|
-
const value = deserialize(raw);
|
|
1039
|
-
if (validate && !validate(value)) return null;
|
|
1040
|
-
return value;
|
|
1041
|
-
} catch {
|
|
1042
|
-
return null;
|
|
1043
|
-
}
|
|
1044
|
-
},
|
|
1045
|
-
set(value) {
|
|
1046
|
-
try {
|
|
1047
|
-
const serialized = serialize(value);
|
|
1048
|
-
sessionStorage.setItem(key, serialized);
|
|
1049
|
-
} catch {
|
|
1050
|
-
}
|
|
1051
|
-
},
|
|
1052
|
-
remove() {
|
|
1053
|
-
sessionStorage.removeItem(key);
|
|
1054
|
-
}
|
|
1055
|
-
};
|
|
1056
|
-
}
|
|
1057
|
-
|
|
1058
|
-
// src/storage/indexed.ts
|
|
1059
|
-
var dbCache = /* @__PURE__ */ new Map();
|
|
1060
|
-
function openDB(dbName, storeName) {
|
|
1061
|
-
const cacheKey = `${dbName}::${storeName}`;
|
|
1062
|
-
const cached = dbCache.get(cacheKey);
|
|
1063
|
-
if (cached) return cached;
|
|
1064
|
-
const promise = new Promise((resolve, reject) => {
|
|
1065
|
-
const probe = indexedDB.open(dbName);
|
|
1066
|
-
probe.onerror = () => reject(probe.error);
|
|
1067
|
-
probe.onsuccess = () => {
|
|
1068
|
-
const db = probe.result;
|
|
1069
|
-
if (db.objectStoreNames.contains(storeName)) {
|
|
1070
|
-
resolve(db);
|
|
1071
|
-
return;
|
|
1072
|
-
}
|
|
1073
|
-
const nextVersion = db.version + 1;
|
|
1074
|
-
db.close();
|
|
1075
|
-
const upgrade = indexedDB.open(dbName, nextVersion);
|
|
1076
|
-
upgrade.onerror = () => reject(upgrade.error);
|
|
1077
|
-
upgrade.onupgradeneeded = () => {
|
|
1078
|
-
const upgradedDB = upgrade.result;
|
|
1079
|
-
if (!upgradedDB.objectStoreNames.contains(storeName)) {
|
|
1080
|
-
upgradedDB.createObjectStore(storeName);
|
|
1081
|
-
}
|
|
1082
|
-
};
|
|
1083
|
-
upgrade.onsuccess = () => resolve(upgrade.result);
|
|
1084
|
-
};
|
|
1085
|
-
probe.onupgradeneeded = () => {
|
|
1086
|
-
const db = probe.result;
|
|
1087
|
-
if (!db.objectStoreNames.contains(storeName)) {
|
|
1088
|
-
db.createObjectStore(storeName);
|
|
1089
|
-
}
|
|
1090
|
-
};
|
|
1091
|
-
});
|
|
1092
|
-
dbCache.set(cacheKey, promise);
|
|
1093
|
-
promise.catch(() => {
|
|
1094
|
-
dbCache.delete(cacheKey);
|
|
1095
|
-
});
|
|
1096
|
-
return promise;
|
|
1097
|
-
}
|
|
1098
|
-
function createIndexedDB(dbName, storeName = "default") {
|
|
1099
|
-
function withStore(mode, fn) {
|
|
1100
|
-
return openDB(dbName, storeName).then(
|
|
1101
|
-
(db) => new Promise((resolve, reject) => {
|
|
1102
|
-
const tx = db.transaction(storeName, mode);
|
|
1103
|
-
const store = tx.objectStore(storeName);
|
|
1104
|
-
const request = fn(store);
|
|
1105
|
-
request.onsuccess = () => resolve(request.result);
|
|
1106
|
-
request.onerror = () => reject(request.error);
|
|
1107
|
-
})
|
|
1108
|
-
);
|
|
1109
|
-
}
|
|
1110
|
-
return {
|
|
1111
|
-
get(key) {
|
|
1112
|
-
return withStore("readonly", (store) => store.get(key));
|
|
1113
|
-
},
|
|
1114
|
-
set(key, value) {
|
|
1115
|
-
return withStore("readwrite", (store) => store.put(value, key)).then(
|
|
1116
|
-
() => void 0
|
|
1117
|
-
);
|
|
1118
|
-
},
|
|
1119
|
-
delete(key) {
|
|
1120
|
-
return withStore("readwrite", (store) => store.delete(key)).then(
|
|
1121
|
-
() => void 0
|
|
1122
|
-
);
|
|
1123
|
-
},
|
|
1124
|
-
getAll() {
|
|
1125
|
-
return withStore("readonly", (store) => store.getAll());
|
|
1126
|
-
},
|
|
1127
|
-
keys() {
|
|
1128
|
-
return withStore("readonly", (store) => store.getAllKeys()).then(
|
|
1129
|
-
(keys) => keys.map(String)
|
|
1130
|
-
);
|
|
1131
|
-
},
|
|
1132
|
-
clear() {
|
|
1133
|
-
return withStore("readwrite", (store) => store.clear()).then(
|
|
1134
|
-
() => void 0
|
|
1135
|
-
);
|
|
1136
|
-
}
|
|
1137
|
-
};
|
|
1138
|
-
}
|
|
1139
|
-
|
|
1140
|
-
// src/http/fetch.ts
|
|
1141
|
-
function createFetch(url, options) {
|
|
1142
|
-
const [data, setData] = chunk3U57L2TY_cjs.createSignal(null);
|
|
1143
|
-
const [error, setError] = chunk3U57L2TY_cjs.createSignal(null);
|
|
1144
|
-
const [loading, setLoading] = chunk3U57L2TY_cjs.createSignal(false);
|
|
1145
|
-
let currentController = null;
|
|
1146
|
-
function resolveURL() {
|
|
1147
|
-
const raw = typeof url === "function" ? url() : url;
|
|
1148
|
-
const base = options?.base ?? "";
|
|
1149
|
-
const fullURL = new URL(raw, base || void 0);
|
|
1150
|
-
if (options?.params) {
|
|
1151
|
-
for (const [key, value] of Object.entries(options.params)) {
|
|
1152
|
-
fullURL.searchParams.set(key, value);
|
|
1153
|
-
}
|
|
1154
|
-
}
|
|
1155
|
-
return fullURL.toString();
|
|
1156
|
-
}
|
|
1157
|
-
async function execute() {
|
|
1158
|
-
if (currentController) {
|
|
1159
|
-
currentController.abort();
|
|
1160
|
-
}
|
|
1161
|
-
currentController = new AbortController();
|
|
1162
|
-
const controller = currentController;
|
|
1163
|
-
const timeoutMs = options?.timeout ?? 3e4;
|
|
1164
|
-
const timeoutId = setTimeout(() => controller.abort(), timeoutMs);
|
|
1165
|
-
setLoading(true);
|
|
1166
|
-
setError(null);
|
|
1167
|
-
try {
|
|
1168
|
-
const resolvedURL = resolveURL();
|
|
1169
|
-
const { base: _base, params: _params, timeout: _timeout, transform, ...fetchInit } = options ?? {};
|
|
1170
|
-
const response = await fetch(resolvedURL, {
|
|
1171
|
-
...fetchInit,
|
|
1172
|
-
signal: controller.signal
|
|
1173
|
-
});
|
|
1174
|
-
if (!response.ok) {
|
|
1175
|
-
throw new Error(`HTTP ${response.status}: ${response.statusText}`);
|
|
1176
|
-
}
|
|
1177
|
-
const json = await response.json();
|
|
1178
|
-
const transformed = transform ? transform(json) : json;
|
|
1179
|
-
setData(transformed);
|
|
1180
|
-
} catch (err) {
|
|
1181
|
-
if (err instanceof Error && err.name === "AbortError") {
|
|
1182
|
-
return;
|
|
1183
|
-
}
|
|
1184
|
-
setError(err instanceof Error ? err : new Error(String(err)));
|
|
1185
|
-
} finally {
|
|
1186
|
-
clearTimeout(timeoutId);
|
|
1187
|
-
if (currentController === controller) {
|
|
1188
|
-
currentController = null;
|
|
1189
|
-
setLoading(false);
|
|
1190
|
-
}
|
|
1191
|
-
}
|
|
1192
|
-
}
|
|
1193
|
-
if (typeof url === "function") {
|
|
1194
|
-
chunkYMIMKO4W_cjs.internalEffect(() => {
|
|
1195
|
-
url();
|
|
1196
|
-
execute();
|
|
1197
|
-
});
|
|
1198
|
-
} else {
|
|
1199
|
-
execute();
|
|
1200
|
-
}
|
|
1201
|
-
return {
|
|
1202
|
-
data,
|
|
1203
|
-
error,
|
|
1204
|
-
loading,
|
|
1205
|
-
refetch: execute,
|
|
1206
|
-
abort() {
|
|
1207
|
-
if (currentController) {
|
|
1208
|
-
currentController.abort();
|
|
1209
|
-
}
|
|
1210
|
-
}
|
|
1211
|
-
};
|
|
1212
|
-
}
|
|
1213
|
-
async function fetchJSON(url, options) {
|
|
1214
|
-
const response = await fetch(url, options);
|
|
1215
|
-
if (!response.ok) {
|
|
1216
|
-
throw new Error(`HTTP ${response.status}: ${response.statusText}`);
|
|
1217
|
-
}
|
|
1218
|
-
return await response.json();
|
|
1219
|
-
}
|
|
1220
|
-
|
|
1221
|
-
// src/http/sse.ts
|
|
1222
|
-
function createSSE(url, options) {
|
|
1223
|
-
const [data, setData] = chunk3U57L2TY_cjs.createSignal(null);
|
|
1224
|
-
const [error, setError] = chunk3U57L2TY_cjs.createSignal(null);
|
|
1225
|
-
const [connected, setConnected] = chunk3U57L2TY_cjs.createSignal(false);
|
|
1226
|
-
const source = new EventSource(url, {
|
|
1227
|
-
withCredentials: options?.withCredentials ?? false
|
|
1228
|
-
});
|
|
1229
|
-
source.onopen = () => {
|
|
1230
|
-
setConnected(true);
|
|
1231
|
-
setError(null);
|
|
1232
|
-
};
|
|
1233
|
-
const parseMessage = options?.parse ?? ((raw) => {
|
|
1234
|
-
try {
|
|
1235
|
-
return JSON.parse(raw);
|
|
1236
|
-
} catch {
|
|
1237
|
-
return raw;
|
|
1238
|
-
}
|
|
1239
|
-
});
|
|
1240
|
-
source.onmessage = (event) => {
|
|
1241
|
-
setData(parseMessage(event.data));
|
|
1242
|
-
};
|
|
1243
|
-
source.onerror = (event) => {
|
|
1244
|
-
setError(event);
|
|
1245
|
-
setConnected(false);
|
|
1246
|
-
};
|
|
1247
|
-
return {
|
|
1248
|
-
data,
|
|
1249
|
-
error,
|
|
1250
|
-
connected,
|
|
1251
|
-
close() {
|
|
1252
|
-
source.close();
|
|
1253
|
-
setConnected(false);
|
|
1254
|
-
},
|
|
1255
|
-
on(event, handler) {
|
|
1256
|
-
const parseEvent = options?.parse ?? ((raw) => {
|
|
1257
|
-
try {
|
|
1258
|
-
return JSON.parse(raw);
|
|
1259
|
-
} catch {
|
|
1260
|
-
return raw;
|
|
1261
|
-
}
|
|
1262
|
-
});
|
|
1263
|
-
const listener = (e) => {
|
|
1264
|
-
handler(parseEvent(e.data));
|
|
1265
|
-
};
|
|
1266
|
-
source.addEventListener(event, listener);
|
|
1267
|
-
return () => {
|
|
1268
|
-
source.removeEventListener(event, listener);
|
|
1269
|
-
};
|
|
1270
|
-
}
|
|
1271
|
-
};
|
|
1272
|
-
}
|
|
1273
|
-
|
|
1274
|
-
// src/http/ws.ts
|
|
1275
|
-
function createWebSocket(url, options) {
|
|
1276
|
-
const shouldReconnect = options?.reconnect ?? true;
|
|
1277
|
-
const baseInterval = options?.reconnectInterval ?? 1e3;
|
|
1278
|
-
const maxReconnects = options?.maxReconnects ?? 5;
|
|
1279
|
-
const [data, setData] = chunk3U57L2TY_cjs.createSignal(null);
|
|
1280
|
-
const [status, setStatus] = chunk3U57L2TY_cjs.createSignal("connecting");
|
|
1281
|
-
const handlers = /* @__PURE__ */ new Set();
|
|
1282
|
-
let socket = null;
|
|
1283
|
-
let reconnectCount = 0;
|
|
1284
|
-
let reconnectTimer = null;
|
|
1285
|
-
let permanentlyClosed = false;
|
|
1286
|
-
function connect() {
|
|
1287
|
-
if (permanentlyClosed) return;
|
|
1288
|
-
setStatus("connecting");
|
|
1289
|
-
socket = new WebSocket(url, options?.protocols);
|
|
1290
|
-
socket.onopen = () => {
|
|
1291
|
-
setStatus("open");
|
|
1292
|
-
reconnectCount = 0;
|
|
1293
|
-
};
|
|
1294
|
-
const parseMessage = options?.parse ?? ((raw) => {
|
|
1295
|
-
try {
|
|
1296
|
-
return JSON.parse(raw);
|
|
1297
|
-
} catch {
|
|
1298
|
-
return raw;
|
|
1299
|
-
}
|
|
1300
|
-
});
|
|
1301
|
-
socket.onmessage = (event) => {
|
|
1302
|
-
const parsed = parseMessage(event.data);
|
|
1303
|
-
setData(parsed);
|
|
1304
|
-
for (const handler of handlers) {
|
|
1305
|
-
handler(parsed);
|
|
1306
|
-
}
|
|
1307
|
-
};
|
|
1308
|
-
socket.onerror = () => {
|
|
1309
|
-
setStatus("error");
|
|
1310
|
-
};
|
|
1311
|
-
socket.onclose = () => {
|
|
1312
|
-
if (permanentlyClosed) {
|
|
1313
|
-
setStatus("closed");
|
|
1314
|
-
return;
|
|
1315
|
-
}
|
|
1316
|
-
setStatus("closed");
|
|
1317
|
-
if (shouldReconnect && reconnectCount < maxReconnects) {
|
|
1318
|
-
const delay = baseInterval * Math.pow(2, reconnectCount);
|
|
1319
|
-
reconnectCount++;
|
|
1320
|
-
reconnectTimer = setTimeout(connect, delay);
|
|
1321
|
-
}
|
|
1322
|
-
};
|
|
1323
|
-
}
|
|
1324
|
-
connect();
|
|
1325
|
-
return {
|
|
1326
|
-
data,
|
|
1327
|
-
status,
|
|
1328
|
-
send(value) {
|
|
1329
|
-
if (socket && socket.readyState === WebSocket.OPEN) {
|
|
1330
|
-
socket.send(JSON.stringify(value));
|
|
1331
|
-
}
|
|
1332
|
-
},
|
|
1333
|
-
close() {
|
|
1334
|
-
permanentlyClosed = true;
|
|
1335
|
-
if (reconnectTimer !== null) {
|
|
1336
|
-
clearTimeout(reconnectTimer);
|
|
1337
|
-
reconnectTimer = null;
|
|
1338
|
-
}
|
|
1339
|
-
if (socket) {
|
|
1340
|
-
socket.close();
|
|
1341
|
-
socket = null;
|
|
1342
|
-
}
|
|
1343
|
-
setStatus("closed");
|
|
1344
|
-
},
|
|
1345
|
-
on(handler) {
|
|
1346
|
-
handlers.add(handler);
|
|
1347
|
-
return () => {
|
|
1348
|
-
handlers.delete(handler);
|
|
1349
|
-
};
|
|
1350
|
-
}
|
|
1351
|
-
};
|
|
1352
|
-
}
|
|
1353
|
-
|
|
1354
|
-
// src/server/action.ts
|
|
1355
|
-
function createAction(serverFn, options) {
|
|
1356
|
-
const [pending, setPending] = chunk3U57L2TY_cjs.createSignal(false);
|
|
1357
|
-
const [error, setError] = chunk3U57L2TY_cjs.createSignal(void 0);
|
|
1358
|
-
const action = async (...args) => {
|
|
1359
|
-
setPending(true);
|
|
1360
|
-
setError(void 0);
|
|
1361
|
-
if (options?.optimistic) {
|
|
1362
|
-
try {
|
|
1363
|
-
chunkYMIMKO4W_cjs.batch(() => options.optimistic(...args));
|
|
1364
|
-
} catch {
|
|
1365
|
-
}
|
|
1366
|
-
}
|
|
1367
|
-
try {
|
|
1368
|
-
const result = await serverFn(...args);
|
|
1369
|
-
if (options?.onSuccess) {
|
|
1370
|
-
chunkYMIMKO4W_cjs.batch(() => options.onSuccess(result, ...args));
|
|
1371
|
-
}
|
|
1372
|
-
if (options?.invalidates) {
|
|
1373
|
-
for (const resource of options.invalidates) {
|
|
1374
|
-
resource.refetch();
|
|
1375
|
-
}
|
|
1376
|
-
}
|
|
1377
|
-
setPending(false);
|
|
1378
|
-
return result;
|
|
1379
|
-
} catch (err) {
|
|
1380
|
-
if (options?.onError) {
|
|
1381
|
-
try {
|
|
1382
|
-
chunkYMIMKO4W_cjs.batch(() => options.onError(err, ...args));
|
|
1383
|
-
} catch {
|
|
1384
|
-
}
|
|
1385
|
-
}
|
|
1386
|
-
setError(err);
|
|
1387
|
-
setPending(false);
|
|
1388
|
-
throw err;
|
|
1389
|
-
}
|
|
1390
|
-
};
|
|
1391
|
-
const typedAction = action;
|
|
1392
|
-
typedAction.pending = pending;
|
|
1393
|
-
typedAction.error = error;
|
|
1394
|
-
typedAction.clearError = () => setError(void 0);
|
|
1395
|
-
return typedAction;
|
|
1396
|
-
}
|
|
1397
|
-
|
|
1398
|
-
// src/server/mutation.ts
|
|
1399
|
-
var resourceRegistry = /* @__PURE__ */ new Map();
|
|
1400
|
-
function registerResource(key, resource) {
|
|
1401
|
-
resourceRegistry.set(key, resource);
|
|
1402
|
-
}
|
|
1403
|
-
function unregisterResource(key) {
|
|
1404
|
-
resourceRegistry.delete(key);
|
|
1405
|
-
}
|
|
1406
|
-
function applyRevalidation(revalidateData) {
|
|
1407
|
-
for (const [key, freshData] of Object.entries(revalidateData)) {
|
|
1408
|
-
const resource = resourceRegistry.get(key);
|
|
1409
|
-
if (resource) {
|
|
1410
|
-
resource.mutate(freshData);
|
|
1411
|
-
}
|
|
1412
|
-
}
|
|
1413
|
-
}
|
|
1414
|
-
function enableAutoRevalidation() {
|
|
1415
|
-
if (typeof window === "undefined") {
|
|
1416
|
-
return () => {
|
|
1417
|
-
};
|
|
1418
|
-
}
|
|
1419
|
-
const handler = (event) => {
|
|
1420
|
-
const detail = event.detail;
|
|
1421
|
-
if (detail && typeof detail === "object") {
|
|
1422
|
-
applyRevalidation(detail);
|
|
1423
|
-
}
|
|
1424
|
-
};
|
|
1425
|
-
window.addEventListener("forma:revalidate", handler);
|
|
1426
|
-
return () => window.removeEventListener("forma:revalidate", handler);
|
|
1427
|
-
}
|
|
1428
|
-
function withRevalidation(data, revalidate) {
|
|
1429
|
-
return { data, __revalidate: revalidate };
|
|
1430
|
-
}
|
|
1431
|
-
|
|
1432
|
-
// src/server/rpc-client.ts
|
|
1433
|
-
function $$serverFunction(endpoint) {
|
|
1434
|
-
const rpcFn = async (...args) => {
|
|
1435
|
-
const response = await fetch(endpoint, {
|
|
1436
|
-
method: "POST",
|
|
1437
|
-
headers: {
|
|
1438
|
-
"Content-Type": "application/json",
|
|
1439
|
-
"X-Forma-RPC": "1"
|
|
1440
|
-
},
|
|
1441
|
-
body: JSON.stringify({ args })
|
|
1442
|
-
});
|
|
1443
|
-
if (!response.ok) {
|
|
1444
|
-
const errorText = await response.text();
|
|
1445
|
-
throw new Error(`Server function failed (${response.status}): ${errorText}`);
|
|
1446
|
-
}
|
|
1447
|
-
const result = await response.json();
|
|
1448
|
-
if (result && typeof result === "object" && "__revalidate" in result) {
|
|
1449
|
-
if (typeof window !== "undefined") {
|
|
1450
|
-
window.dispatchEvent(new CustomEvent("forma:revalidate", {
|
|
1451
|
-
detail: result.__revalidate
|
|
1452
|
-
}));
|
|
1453
|
-
}
|
|
1454
|
-
return result.data;
|
|
1455
|
-
}
|
|
1456
|
-
return result;
|
|
1457
|
-
};
|
|
1458
|
-
return rpcFn;
|
|
1459
|
-
}
|
|
1460
|
-
|
|
1461
|
-
// src/server/rpc-handler.ts
|
|
1462
|
-
var registry = /* @__PURE__ */ new Map();
|
|
1463
|
-
function registerServerFunction(endpoint, fn) {
|
|
1464
|
-
registry.set(endpoint, fn);
|
|
1465
|
-
}
|
|
1466
|
-
function getServerFunction(endpoint) {
|
|
1467
|
-
return registry.get(endpoint);
|
|
1468
|
-
}
|
|
1469
|
-
function getRegisteredEndpoints() {
|
|
1470
|
-
return [...registry.keys()];
|
|
1471
|
-
}
|
|
1472
|
-
var FORBIDDEN_KEYS = /* @__PURE__ */ new Set(["__proto__", "constructor", "prototype"]);
|
|
1473
|
-
async function handleRPC(endpoint, body, revalidateData) {
|
|
1474
|
-
const endpointName = endpoint.split("/").pop() ?? "";
|
|
1475
|
-
if (FORBIDDEN_KEYS.has(endpointName)) {
|
|
1476
|
-
return { error: "Forbidden endpoint name" };
|
|
1477
|
-
}
|
|
1478
|
-
const fn = registry.get(endpoint);
|
|
1479
|
-
if (!fn) {
|
|
1480
|
-
return { error: `Unknown server function: ${endpoint}` };
|
|
1481
|
-
}
|
|
1482
|
-
try {
|
|
1483
|
-
const result = await fn(...body.args);
|
|
1484
|
-
if (revalidateData) {
|
|
1485
|
-
return { data: result, __revalidate: revalidateData };
|
|
1486
|
-
}
|
|
1487
|
-
return { data: result };
|
|
1488
|
-
} catch (err) {
|
|
1489
|
-
const isDev = typeof process !== "undefined" && process.env?.NODE_ENV === "development";
|
|
1490
|
-
const message = isDev && err instanceof Error ? err.message : "Internal server error";
|
|
1491
|
-
return { error: message };
|
|
1492
|
-
}
|
|
1493
|
-
}
|
|
1494
|
-
function createRPCMiddleware() {
|
|
1495
|
-
return async (req, res) => {
|
|
1496
|
-
if (req.method !== "POST") {
|
|
1497
|
-
res.status(405).json({ error: "Method not allowed" });
|
|
1498
|
-
return;
|
|
1499
|
-
}
|
|
1500
|
-
const body = req.body;
|
|
1501
|
-
if (!body || !Array.isArray(body.args)) {
|
|
1502
|
-
res.status(400).json({ error: "Invalid RPC request: missing args array" });
|
|
1503
|
-
return;
|
|
1504
|
-
}
|
|
1505
|
-
const result = await handleRPC(req.url, body);
|
|
1506
|
-
if (result.error) {
|
|
1507
|
-
res.status(500).json(result);
|
|
1508
|
-
} else {
|
|
1509
|
-
res.json(result);
|
|
1510
|
-
}
|
|
1511
|
-
};
|
|
1512
|
-
}
|
|
1513
|
-
|
|
1514
997
|
Object.defineProperty(exports, "Fragment", {
|
|
1515
998
|
enumerable: true,
|
|
1516
|
-
get: function () { return
|
|
999
|
+
get: function () { return chunkV732ZBCU_cjs.Fragment; }
|
|
1517
1000
|
});
|
|
1518
|
-
Object.defineProperty(exports, "
|
|
1001
|
+
Object.defineProperty(exports, "cleanup", {
|
|
1519
1002
|
enumerable: true,
|
|
1520
|
-
get: function () { return
|
|
1003
|
+
get: function () { return chunkV732ZBCU_cjs.cleanup; }
|
|
1521
1004
|
});
|
|
1522
|
-
Object.defineProperty(exports, "
|
|
1005
|
+
Object.defineProperty(exports, "createList", {
|
|
1523
1006
|
enumerable: true,
|
|
1524
|
-
get: function () { return
|
|
1007
|
+
get: function () { return chunkV732ZBCU_cjs.createList; }
|
|
1525
1008
|
});
|
|
1526
|
-
Object.defineProperty(exports, "
|
|
1009
|
+
Object.defineProperty(exports, "createShow", {
|
|
1527
1010
|
enumerable: true,
|
|
1528
|
-
get: function () { return
|
|
1011
|
+
get: function () { return chunkV732ZBCU_cjs.createShow; }
|
|
1529
1012
|
});
|
|
1530
|
-
Object.defineProperty(exports, "
|
|
1013
|
+
Object.defineProperty(exports, "fragment", {
|
|
1531
1014
|
enumerable: true,
|
|
1532
|
-
get: function () { return
|
|
1015
|
+
get: function () { return chunkV732ZBCU_cjs.fragment; }
|
|
1533
1016
|
});
|
|
1534
|
-
Object.defineProperty(exports, "
|
|
1017
|
+
Object.defineProperty(exports, "h", {
|
|
1535
1018
|
enumerable: true,
|
|
1536
|
-
get: function () { return
|
|
1019
|
+
get: function () { return chunkV732ZBCU_cjs.h; }
|
|
1537
1020
|
});
|
|
1538
|
-
Object.defineProperty(exports, "
|
|
1021
|
+
Object.defineProperty(exports, "hydrateIsland", {
|
|
1539
1022
|
enumerable: true,
|
|
1540
|
-
get: function () { return
|
|
1023
|
+
get: function () { return chunkV732ZBCU_cjs.hydrateIsland; }
|
|
1541
1024
|
});
|
|
1542
|
-
Object.defineProperty(exports, "
|
|
1025
|
+
Object.defineProperty(exports, "reconcileList", {
|
|
1543
1026
|
enumerable: true,
|
|
1544
|
-
get: function () { return
|
|
1027
|
+
get: function () { return chunkV732ZBCU_cjs.reconcileList; }
|
|
1545
1028
|
});
|
|
1546
|
-
Object.defineProperty(exports, "
|
|
1029
|
+
Object.defineProperty(exports, "batch", {
|
|
1547
1030
|
enumerable: true,
|
|
1548
|
-
get: function () { return
|
|
1031
|
+
get: function () { return chunkDCTOXHPF_cjs.batch; }
|
|
1549
1032
|
});
|
|
1550
|
-
Object.defineProperty(exports, "
|
|
1033
|
+
Object.defineProperty(exports, "createEffect", {
|
|
1551
1034
|
enumerable: true,
|
|
1552
|
-
get: function () { return
|
|
1035
|
+
get: function () { return chunkDCTOXHPF_cjs.createEffect; }
|
|
1553
1036
|
});
|
|
1554
|
-
Object.defineProperty(exports, "
|
|
1037
|
+
Object.defineProperty(exports, "createMemo", {
|
|
1555
1038
|
enumerable: true,
|
|
1556
|
-
get: function () { return
|
|
1039
|
+
get: function () { return chunkDCTOXHPF_cjs.createMemo; }
|
|
1557
1040
|
});
|
|
1558
|
-
Object.defineProperty(exports, "
|
|
1041
|
+
Object.defineProperty(exports, "createReducer", {
|
|
1559
1042
|
enumerable: true,
|
|
1560
|
-
get: function () { return
|
|
1043
|
+
get: function () { return chunkDCTOXHPF_cjs.createReducer; }
|
|
1561
1044
|
});
|
|
1562
|
-
Object.defineProperty(exports, "
|
|
1045
|
+
Object.defineProperty(exports, "createRef", {
|
|
1563
1046
|
enumerable: true,
|
|
1564
|
-
get: function () { return
|
|
1047
|
+
get: function () { return chunkDCTOXHPF_cjs.createRef; }
|
|
1565
1048
|
});
|
|
1566
|
-
Object.defineProperty(exports, "
|
|
1049
|
+
Object.defineProperty(exports, "createResource", {
|
|
1567
1050
|
enumerable: true,
|
|
1568
|
-
get: function () { return
|
|
1051
|
+
get: function () { return chunkDCTOXHPF_cjs.createResource; }
|
|
1569
1052
|
});
|
|
1570
|
-
Object.defineProperty(exports, "
|
|
1053
|
+
Object.defineProperty(exports, "createRoot", {
|
|
1571
1054
|
enumerable: true,
|
|
1572
|
-
get: function () { return
|
|
1055
|
+
get: function () { return chunkDCTOXHPF_cjs.createRoot; }
|
|
1056
|
+
});
|
|
1057
|
+
Object.defineProperty(exports, "getBatchDepth", {
|
|
1058
|
+
enumerable: true,
|
|
1059
|
+
get: function () { return chunkDCTOXHPF_cjs.getBatchDepth; }
|
|
1573
1060
|
});
|
|
1574
1061
|
Object.defineProperty(exports, "isComputed", {
|
|
1575
1062
|
enumerable: true,
|
|
1576
|
-
get: function () { return
|
|
1063
|
+
get: function () { return chunkDCTOXHPF_cjs.isComputed; }
|
|
1577
1064
|
});
|
|
1578
1065
|
Object.defineProperty(exports, "isEffect", {
|
|
1579
1066
|
enumerable: true,
|
|
1580
|
-
get: function () { return
|
|
1067
|
+
get: function () { return chunkDCTOXHPF_cjs.isEffect; }
|
|
1581
1068
|
});
|
|
1582
1069
|
Object.defineProperty(exports, "isEffectScope", {
|
|
1583
1070
|
enumerable: true,
|
|
1584
|
-
get: function () { return
|
|
1071
|
+
get: function () { return chunkDCTOXHPF_cjs.isEffectScope; }
|
|
1585
1072
|
});
|
|
1586
1073
|
Object.defineProperty(exports, "isSignal", {
|
|
1587
1074
|
enumerable: true,
|
|
1588
|
-
get: function () { return
|
|
1075
|
+
get: function () { return chunkDCTOXHPF_cjs.isSignal; }
|
|
1589
1076
|
});
|
|
1590
1077
|
Object.defineProperty(exports, "on", {
|
|
1591
1078
|
enumerable: true,
|
|
1592
|
-
get: function () { return
|
|
1079
|
+
get: function () { return chunkDCTOXHPF_cjs.on; }
|
|
1593
1080
|
});
|
|
1594
1081
|
Object.defineProperty(exports, "onCleanup", {
|
|
1595
1082
|
enumerable: true,
|
|
1596
|
-
get: function () { return
|
|
1083
|
+
get: function () { return chunkDCTOXHPF_cjs.onCleanup; }
|
|
1597
1084
|
});
|
|
1598
1085
|
Object.defineProperty(exports, "onError", {
|
|
1599
1086
|
enumerable: true,
|
|
1600
|
-
get: function () { return
|
|
1601
|
-
});
|
|
1602
|
-
Object.defineProperty(exports, "reconcileList", {
|
|
1603
|
-
enumerable: true,
|
|
1604
|
-
get: function () { return chunkYMIMKO4W_cjs.reconcileList; }
|
|
1087
|
+
get: function () { return chunkDCTOXHPF_cjs.onError; }
|
|
1605
1088
|
});
|
|
1606
1089
|
Object.defineProperty(exports, "trigger", {
|
|
1607
1090
|
enumerable: true,
|
|
1608
|
-
get: function () { return
|
|
1091
|
+
get: function () { return chunkDCTOXHPF_cjs.trigger; }
|
|
1609
1092
|
});
|
|
1610
1093
|
Object.defineProperty(exports, "untrack", {
|
|
1611
1094
|
enumerable: true,
|
|
1612
|
-
get: function () { return
|
|
1095
|
+
get: function () { return chunkDCTOXHPF_cjs.untrack; }
|
|
1613
1096
|
});
|
|
1614
1097
|
Object.defineProperty(exports, "createComputed", {
|
|
1615
1098
|
enumerable: true,
|
|
@@ -1621,39 +1104,24 @@ Object.defineProperty(exports, "createSignal", {
|
|
|
1621
1104
|
});
|
|
1622
1105
|
exports.$ = $;
|
|
1623
1106
|
exports.$$ = $$;
|
|
1624
|
-
exports.$$serverFunction = $$serverFunction;
|
|
1625
1107
|
exports.activateIslands = activateIslands;
|
|
1626
1108
|
exports.addClass = addClass;
|
|
1627
|
-
exports.applyRevalidation = applyRevalidation;
|
|
1628
1109
|
exports.children = children;
|
|
1629
1110
|
exports.closest = closest;
|
|
1630
|
-
exports.createAction = createAction;
|
|
1631
1111
|
exports.createBus = createBus;
|
|
1632
1112
|
exports.createContext = createContext;
|
|
1633
1113
|
exports.createErrorBoundary = createErrorBoundary;
|
|
1634
|
-
exports.createFetch = createFetch;
|
|
1635
1114
|
exports.createHistory = createHistory;
|
|
1636
|
-
exports.createIndexedDB = createIndexedDB;
|
|
1637
|
-
exports.createLocalStorage = createLocalStorage;
|
|
1638
1115
|
exports.createPortal = createPortal;
|
|
1639
|
-
exports.createRPCMiddleware = createRPCMiddleware;
|
|
1640
|
-
exports.createSSE = createSSE;
|
|
1641
|
-
exports.createSessionStorage = createSessionStorage;
|
|
1642
1116
|
exports.createStore = createStore;
|
|
1643
1117
|
exports.createSuspense = createSuspense;
|
|
1644
1118
|
exports.createSwitch = createSwitch;
|
|
1645
1119
|
exports.createText = createText;
|
|
1646
|
-
exports.createWebSocket = createWebSocket;
|
|
1647
1120
|
exports.deactivateAllIslands = deactivateAllIslands;
|
|
1648
1121
|
exports.deactivateIsland = deactivateIsland;
|
|
1649
1122
|
exports.defineComponent = defineComponent;
|
|
1650
1123
|
exports.delegate = delegate;
|
|
1651
1124
|
exports.disposeComponent = disposeComponent;
|
|
1652
|
-
exports.enableAutoRevalidation = enableAutoRevalidation;
|
|
1653
|
-
exports.fetchJSON = fetchJSON;
|
|
1654
|
-
exports.getRegisteredEndpoints = getRegisteredEndpoints;
|
|
1655
|
-
exports.getServerFunction = getServerFunction;
|
|
1656
|
-
exports.handleRPC = handleRPC;
|
|
1657
1125
|
exports.inject = inject;
|
|
1658
1126
|
exports.mount = mount;
|
|
1659
1127
|
exports.nextSibling = nextSibling;
|
|
@@ -1667,8 +1135,6 @@ exports.parent = parent;
|
|
|
1667
1135
|
exports.persist = persist;
|
|
1668
1136
|
exports.prevSibling = prevSibling;
|
|
1669
1137
|
exports.provide = provide;
|
|
1670
|
-
exports.registerResource = registerResource;
|
|
1671
|
-
exports.registerServerFunction = registerServerFunction;
|
|
1672
1138
|
exports.removeClass = removeClass;
|
|
1673
1139
|
exports.setAttr = setAttr;
|
|
1674
1140
|
exports.setHTML = setHTML;
|
|
@@ -1679,7 +1145,5 @@ exports.siblings = siblings;
|
|
|
1679
1145
|
exports.toggleClass = toggleClass;
|
|
1680
1146
|
exports.trackDisposer = trackDisposer;
|
|
1681
1147
|
exports.unprovide = unprovide;
|
|
1682
|
-
exports.unregisterResource = unregisterResource;
|
|
1683
|
-
exports.withRevalidation = withRevalidation;
|
|
1684
1148
|
//# sourceMappingURL=index.cjs.map
|
|
1685
1149
|
//# sourceMappingURL=index.cjs.map
|