#292 - allow a full-text search to go through the contents of the pages/articles.
To offer this functionality, the search index needs to be maintained in the file storage, meaning that the search logic needs to move from the webview to the extension worker context.
#292 - allow a full-text search to go through the contents of the pages/articles.
To offer this functionality, the search index needs to be maintained in the file storage, meaning that the search logic needs to move from the webview to the extension worker context.
<!-- github-sync-id:1175277538 -->
I'm already generating json files for full text search on my sites. Maybe if you specify a json data structure that we can put in the root of our project, we can point your search function to it, if we want to add full text search to the extension UI.
I'm already generating json files for full text search on my sites. Maybe if you specify a json data structure that we can put in the root of our project, we can point your search function to it, if we want to add full text search to the extension UI.
Here is an example of one of my search index files. https://www.femtc.com/search.json
<!-- github-comment-id:1074271867 -->
@bwklein it might start to create conflicts. Internally the extension was already using Fuse.js, but was not indexing the body content. In the upcoming beta, this will be changed.
@bwklein it might start to create conflicts. Internally the extension was already using Fuse.js, but was not indexing the `body` content. In the upcoming beta, this will be changed.
<!-- github-comment-id:1076123949 -->
@estruyf this is great! It will have an advantage of not requiring any specific setup for search to work. Plus, just knowing that a word is in a file is enough, I don't really need to have a link to the specific section of the document like I do with my more advanced search index/results.
@estruyf this is great! It will have an advantage of not requiring any specific setup for search to work. Plus, just knowing that a word is in a file is enough, I don't really need to have a link to the specific section of the document like I do with my more advanced search index/results.
<!-- github-comment-id:1076477057 -->
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
#292 - allow a full-text search to go through the contents of the pages/articles.
To offer this functionality, the search index needs to be maintained in the file storage, meaning that the search logic needs to move from the webview to the extension worker context.
I'm already generating json files for full text search on my sites. Maybe if you specify a json data structure that we can put in the root of our project, we can point your search function to it, if we want to add full text search to the extension UI.
Here is an example of one of my search index files. https://www.femtc.com/search.json
@bwklein which library do you use for the search experience on the website?
For that site I am using https://www.meilisearch.com/ but for smaller Hugo sites I use something like this.
Index the content to json. ( Ex. https://psrfcu.org/index.json )
layouts/_default/index.jsonJavaScript search function that uses jQuery (I'm lazy and haven't rewritten this yet to Vanilla js).
static/js/search.jsThe Hugo search page that brings it all together.
layouts/_default/search.html@bwklein it might start to create conflicts. Internally the extension was already using Fuse.js, but was not indexing the
bodycontent. In the upcoming beta, this will be changed.@grahampcharles this is enabled in the latest beta
@estruyf this is great! It will have an advantage of not requiring any specific setup for search to work. Plus, just knowing that a word is in a file is enough, I don't really need to have a link to the specific section of the document like I do with my more advanced search index/results.