Closed eklem closed 3 months ago
But the ESM-version is maybe only made for NodeJS and not the browser?
I think it should just be available as a global variable SearchIndex
:)
It is in search-index-4.0.0.js (UMD), but not the ESM - search-index-esm-4.0.0.js
Ah right yes. In the newest version, it is ESM compatible by default.
on npm as search-index@5.0.0-rc1
If that works, I can also start on a simple service worker for seach-index, importing the different things you need into the service worker. I'll test it later today.
You deprecated 5.0.0-rc1
?
I can't remember exactly why I did that, but I probably published it as the latest version by accident, and then depredated it in a panic just to make sure that nobody actually used it! (strictly speaking it should be published with tag: next
)
Is it possible with a 5.0.0-rc2
with the next
tag? So i can play around with the geo-search-helper demo =)
Sorry that I missed that last question @eklem !
search-index@5.0.0
is now out and this should all just work (let me know if it doesnt 🙂)
Nice. I have a simple geo-search demo I want to build. And I want to slowly learn how to use it with a service worker. So now it is!
Hi @fergiemcdowall! I'm trying to import the ESM-version to run in the browser, but not sure what's exported from
search-index-esm-4.0.0.js
?In HTML:
In geo-search-app.mjs
Then I get an error-message, saying
That's why I'm wondering what search-index is exported as?