I've used Lunr a few times and I'm now taking a look at prebuilt indexes. It works as advertised, but I've noticed a problem. If I want to display results and use the ref property, then I need to load the data the originally created the index as well. So previously my logic was:
load in data
create an index
etc
With a prebuilt index, I thought I'd just need:
load in index
create from what I just loaded
etc
But it looks like I'll need to do:
load in data
load in index
create from what I just loaded
So two network calls instead of one - but in theory, still better as I'm not creating the index on the fly.
I've used Lunr a few times and I'm now taking a look at prebuilt indexes. It works as advertised, but I've noticed a problem. If I want to display results and use the ref property, then I need to load the data the originally created the index as well. So previously my logic was:
load in data create an index etc
With a prebuilt index, I thought I'd just need:
load in index create from what I just loaded etc
But it looks like I'll need to do:
load in data load in index create from what I just loaded
So two network calls instead of one - but in theory, still better as I'm not creating the index on the fly.
Is this understanding correctly?