forked from matrix/element-web
Add localforage support for persisting dendrite data
This commit is contained in:
parent
4828869515
commit
b0fb043c2b
|
@ -66,6 +66,7 @@
|
||||||
"gemini-scrollbar": "github:matrix-org/gemini-scrollbar#91e1e566",
|
"gemini-scrollbar": "github:matrix-org/gemini-scrollbar#91e1e566",
|
||||||
"gfm.css": "^1.1.2",
|
"gfm.css": "^1.1.2",
|
||||||
"highlight.js": "^9.13.1",
|
"highlight.js": "^9.13.1",
|
||||||
|
"localforage": "^1.7.3",
|
||||||
"matrix-js-sdk": "5.1.1",
|
"matrix-js-sdk": "5.1.1",
|
||||||
"matrix-react-sdk": "github:matrix-org/matrix-react-sdk#p2p",
|
"matrix-react-sdk": "github:matrix-org/matrix-react-sdk#p2p",
|
||||||
"olm": "https://packages.matrix.org/npm/olm/olm-3.1.4.tgz",
|
"olm": "https://packages.matrix.org/npm/olm/olm-3.1.4.tgz",
|
||||||
|
|
|
@ -31,7 +31,8 @@ self.registration.addEventListener('updatefound', () => {
|
||||||
|
|
||||||
self.importScripts(`${bundle_path}/wasm_exec.js`,
|
self.importScripts(`${bundle_path}/wasm_exec.js`,
|
||||||
`${bundle_path}/go_http_bridge.js`,
|
`${bundle_path}/go_http_bridge.js`,
|
||||||
`${bundle_path}/sqlitejs.js`)
|
`${bundle_path}/sqlitejs.js`,
|
||||||
|
`${bundle_path}/localforage.js`)
|
||||||
|
|
||||||
function initDendrite() {
|
function initDendrite() {
|
||||||
console.log(`dendrite-sw.js: v${version} SW init`)
|
console.log(`dendrite-sw.js: v${version} SW init`)
|
||||||
|
|
|
@ -36,6 +36,7 @@ module.exports = (env, argv) => {
|
||||||
"dendrite_sw": "./src/vector/dendrite-sw.js",
|
"dendrite_sw": "./src/vector/dendrite-sw.js",
|
||||||
"mobileguide": "./src/vector/mobile_guide/index.js",
|
"mobileguide": "./src/vector/mobile_guide/index.js",
|
||||||
"sqlitejs": "./src/vector/sqlitejs.js",
|
"sqlitejs": "./src/vector/sqlitejs.js",
|
||||||
|
"localforage": "./node_modules/localforage/dist/localforage.min.js",
|
||||||
"go_http_bridge": "./node_modules/go-http-js-libp2p/js/bridge.js",
|
"go_http_bridge": "./node_modules/go-http-js-libp2p/js/bridge.js",
|
||||||
"sql_wasm": "./node_modules/sql.js/dist/sql-wasm.wasm",
|
"sql_wasm": "./node_modules/sql.js/dist/sql-wasm.wasm",
|
||||||
"dendrite_wasm": "./src/vector/dendrite.wasm",
|
"dendrite_wasm": "./src/vector/dendrite.wasm",
|
||||||
|
|
19
yarn.lock
19
yarn.lock
|
@ -5740,6 +5740,11 @@ ignore@^5.1.4:
|
||||||
resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.1.4.tgz#84b7b3dbe64552b6ef0eca99f6743dbec6d97adf"
|
resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.1.4.tgz#84b7b3dbe64552b6ef0eca99f6743dbec6d97adf"
|
||||||
integrity sha512-MzbUSahkTW1u7JpKKjY7LCARd1fU5W2rLdxlM4kdkayuCwZImjkpluF9CM1aLewYJguPDqewLam18Y6AU69A8A==
|
integrity sha512-MzbUSahkTW1u7JpKKjY7LCARd1fU5W2rLdxlM4kdkayuCwZImjkpluF9CM1aLewYJguPDqewLam18Y6AU69A8A==
|
||||||
|
|
||||||
|
immediate@~3.0.5:
|
||||||
|
version "3.0.6"
|
||||||
|
resolved "https://registry.yarnpkg.com/immediate/-/immediate-3.0.6.tgz#9db1dbd0faf8de6fbe0f5dd5e56bb606280de69b"
|
||||||
|
integrity sha1-nbHb0Pr43m++D13V5Wu2BigN5ps=
|
||||||
|
|
||||||
immutable@^3.7.4:
|
immutable@^3.7.4:
|
||||||
version "3.8.2"
|
version "3.8.2"
|
||||||
resolved "https://registry.yarnpkg.com/immutable/-/immutable-3.8.2.tgz#c2439951455bb39913daf281376f1530e104adf3"
|
resolved "https://registry.yarnpkg.com/immutable/-/immutable-3.8.2.tgz#c2439951455bb39913daf281376f1530e104adf3"
|
||||||
|
@ -7159,6 +7164,13 @@ levn@^0.3.0, levn@~0.3.0:
|
||||||
prelude-ls "~1.1.2"
|
prelude-ls "~1.1.2"
|
||||||
type-check "~0.3.2"
|
type-check "~0.3.2"
|
||||||
|
|
||||||
|
lie@3.1.1:
|
||||||
|
version "3.1.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/lie/-/lie-3.1.1.tgz#9a436b2cc7746ca59de7a41fa469b3efb76bd87e"
|
||||||
|
integrity sha1-mkNrLMd0bKWd56QfpGmz77dr2H4=
|
||||||
|
dependencies:
|
||||||
|
immediate "~3.0.5"
|
||||||
|
|
||||||
lines-and-columns@^1.1.6:
|
lines-and-columns@^1.1.6:
|
||||||
version "1.1.6"
|
version "1.1.6"
|
||||||
resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00"
|
resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00"
|
||||||
|
@ -7219,6 +7231,13 @@ loader-utils@^1.0.2, loader-utils@^1.1.0, loader-utils@^1.2.3, loader-utils@^1.4
|
||||||
emojis-list "^3.0.0"
|
emojis-list "^3.0.0"
|
||||||
json5 "^1.0.1"
|
json5 "^1.0.1"
|
||||||
|
|
||||||
|
localforage@^1.7.3:
|
||||||
|
version "1.7.3"
|
||||||
|
resolved "https://registry.yarnpkg.com/localforage/-/localforage-1.7.3.tgz#0082b3ca9734679e1bd534995bdd3b24cf10f204"
|
||||||
|
integrity sha512-1TulyYfc4udS7ECSBT2vwJksWbkwwTX8BzeUIiq8Y07Riy7bDAAnxDaPU/tWyOVmQAcWJIEIFP9lPfBGqVoPgQ==
|
||||||
|
dependencies:
|
||||||
|
lie "3.1.1"
|
||||||
|
|
||||||
locate-path@^2.0.0:
|
locate-path@^2.0.0:
|
||||||
version "2.0.0"
|
version "2.0.0"
|
||||||
resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e"
|
resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e"
|
||||||
|
|
Loading…
Reference in New Issue