@unvired/react-native-unvired-sdk 0.0.35 → 0.0.36
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/BuildNo.txt +1 -1
- package/dist/database/services/DatabaseWeb.js +24 -6
- package/package.json +1 -1
package/BuildNo.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
R-0.000.
|
|
1
|
+
R-0.000.0036
|
|
@@ -12,12 +12,30 @@ function getSqlJs() {
|
|
|
12
12
|
catch {
|
|
13
13
|
initSqlJs = globalThis.initSqlJs;
|
|
14
14
|
}
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
if (typeof initSqlJs === "function") {
|
|
16
|
+
initPromise = initSqlJs({
|
|
17
|
+
locateFile: (file) => {
|
|
18
|
+
if (typeof window !== "undefined" && window.SQL_WASM_PATH) {
|
|
19
|
+
return `${window.SQL_WASM_PATH}/${file}`;
|
|
20
|
+
}
|
|
21
|
+
return `https://cdn.jsdelivr.net/npm/sql.js@1.14.2/dist/${file}`;
|
|
22
|
+
},
|
|
23
|
+
}).then((sql) => {
|
|
24
|
+
SQL = sql;
|
|
25
|
+
return sql;
|
|
26
|
+
}).catch((err) => {
|
|
27
|
+
console.warn("[DatabaseWeb] Failed loading sql.js from jsdelivr, trying cdnjs fallback:", err);
|
|
28
|
+
return initSqlJs({
|
|
29
|
+
locateFile: (file) => `https://cdnjs.cloudflare.com/ajax/libs/sql.js/1.12.0/${file}`,
|
|
30
|
+
}).then((sql) => {
|
|
31
|
+
SQL = sql;
|
|
32
|
+
return sql;
|
|
33
|
+
});
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
initPromise = Promise.reject(new Error("sql.js module not found"));
|
|
38
|
+
}
|
|
21
39
|
}
|
|
22
40
|
return initPromise || Promise.reject(new Error("sql.js not initialized"));
|
|
23
41
|
}
|
package/package.json
CHANGED