mirror of
https://github.com/kiwix/kiwix-js-pwa.git
synced 2025-09-18 08:47:35 -04:00
Use ASM only (experiment)
Former-commit-id: d27bc1d7e935a10cf1ab15f9f4e819300823baf7
This commit is contained in:
parent
ba09842b26
commit
bdde94a47d
@ -227,7 +227,9 @@ if ('WebAssembly' in self) {
|
|||||||
} else {
|
} else {
|
||||||
precacheFiles.push(
|
precacheFiles.push(
|
||||||
"www/js/lib/xzdec-asm.js",
|
"www/js/lib/xzdec-asm.js",
|
||||||
"www/js/lib/zstddec-asm.js"
|
"www/js/lib/zstddec-asm.js",
|
||||||
|
"www/js/lib/libzim-asm.js",
|
||||||
|
"www/js/lib/libzim-asm.js.mem"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
1
www/js/lib/libzim-asm.js.REMOVED.git-id
Normal file
1
www/js/lib/libzim-asm.js.REMOVED.git-id
Normal file
@ -0,0 +1 @@
|
|||||||
|
d427a780021f37961e7a1ed0df634eadf2c02112
|
BIN
www/js/lib/libzim-asm.js.mem
Normal file
BIN
www/js/lib/libzim-asm.js.mem
Normal file
Binary file not shown.
@ -93,7 +93,7 @@ define(['zimfile', 'zimDirEntry', 'transformZimit', 'util', 'uiUtil', 'utf8'],
|
|||||||
var isSplitZim = /\.zima.$/i.test(that._file._files[0].name);
|
var isSplitZim = /\.zima.$/i.test(that._file._files[0].name);
|
||||||
if ('WebAssembly' in self && that._file.fullTextIndex && !isSplitZim) {
|
if ('WebAssembly' in self && that._file.fullTextIndex && !isSplitZim) {
|
||||||
console.log('Instantiating libzim Web Worker...');
|
console.log('Instantiating libzim Web Worker...');
|
||||||
libzimWorker = new Worker('js/lib/libzim-wasm.js');
|
libzimWorker = new Worker('js/lib/libzim-asm.js');
|
||||||
that.callLibzimWorker({action: "init", files: that._file._files})
|
that.callLibzimWorker({action: "init", files: that._file._files})
|
||||||
.then(function () {
|
.then(function () {
|
||||||
params.searchProvider = 'fulltext';
|
params.searchProvider = 'fulltext';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user