noaa-fisheries-integrated-toolbox / resources

Source code for the FIT software development resources
https://noaa-fisheries-integrated-toolbox.github.io/resources
The Unlicense
0 stars 5 forks source link

search not set up #26

Closed k-doering-NOAA closed 1 year ago

k-doering-NOAA commented 1 year ago

when searching, the results have broken links, due to trying to connect to a "local host".

k-doering-NOAA commented 1 year ago

Search is using https://lunrjs.com/ and I suspect it has not been properly set up, but is just reading in results from this file: https://github.com/noaa-fisheries-integrated-toolbox/resources/blob/faf4f8e3f4a889fb21aece3a6dc18de63e1be221/assets/js/lunr/lunr-store.js

So it is not providing actual site search results.

k-doering-NOAA commented 1 year ago

This provides some advice on how to get lunr working with jekyll static sites: https://rayhightower.com/blog/2016/01/04/how-to-make-lunrjs-jekyll-work-together/

k-doering-NOAA commented 1 year ago

after much exploration, the solution was simple: just delete the file called lunr-store.js.

I think now that the index is probably being built on the fly; if the site got very large, we may want to prebuild the index, which is what lunr-store.js was demoing.