10 ms·
Is there a way to run it in WASM, to get something like Lunr[1]? We prefer to do our (small-index, <2MB) search client-side for a bunch of reasons, currently us
by rsstack 4y ago
Is there a way to run it in WASM, to get something like Lunr[1]? We prefer to do our (small-index, <2MB) search client-side for a bunch of reasons, currently using Lunr.js, but it's a bit annoying and the typeahead search is something I improvised and not really official.
[1] https://lunrjs.com/ https://lunrjs.com/
- sandstrom 4y agoYou could have a look at https://github.com/lucaong/minisearch/ https://github.com/lucaong/minisearch/
- rsstack 4y agoWow, this might fit our needs much better! Thanks!
- tmikaeld 4y agoHot tip, we experimented with running minisearch in RAM on cloudflare workers and it works excellent for up to 5MB of index due to it being under the 50ms CPU time. This means, 10M search requests for 5$. The only drawback is that it's expensive to re-index, but if your use case don't require that, it's hard to beat!
- nickreese 4y agoCan vouch for minisearch. Amazing for relative small data that fits in memory. The typeahead is great.