lucivy-wasm 3.0.2 → 3.0.4

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 CHANGED
@@ -1,4 +1,4 @@
1
- # lucivy-wasm 3.0.2
1
+ # lucivy-wasm 3.0.4
2
2
 
3
3
  Fast BM25 full-text search for browsers — WASM build with **threading** (emscripten pthreads), OPFS persistence, and snapshot/delta sync support. Runs in a Web Worker.
4
4
 
@@ -254,8 +254,13 @@ self.onmessage = async (e) => {
254
254
 
255
255
  switch (type) {
256
256
  case 'init': {
257
- const { default: createLucivy } = await import('../pkg/lucivy.js');
257
+ // The page's cache-buster (`?v=`) rides on this worker's URL;
258
+ // pass it on to the engine script and, through locateFile, to
259
+ // the wasm it fetches.
260
+ const bust = self.location.search || '';
261
+ const { default: createLucivy } = await import('../pkg/lucivy.js' + bust);
258
262
  Module = await createLucivy({
263
+ locateFile: (path, prefix) => prefix + path + (path.endsWith('.wasm') ? bust : ''),
259
264
  // Intercept eprintln! from ALL pthreads and send to diag server.
260
265
  printErr: function(text) {
261
266
  diagSendLog(text);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lucivy-wasm",
3
- "version": "3.0.2",
3
+ "version": "3.0.4",
4
4
  "type": "module",
5
5
  "description": "Fast BM25 full-text search for browsers — WASM build of Lucivy with threading, OPFS persistence, and LUCE snapshot support",
6
6
  "license": "MIT",
package/pkg/lucivy.wasm CHANGED
Binary file