gatsby-plugin-lunr icon indicating copy to clipboard operation
gatsby-plugin-lunr copied to clipboard

Whitelisting metadata?

Open mikepspc opened this issue 4 years ago • 1 comments

https://lunrjs.com/guides/core_concepts.html mentions:

Storing metadata about the term and field is opt-in, this is to keep the size of the search index as small as possible. To enable positions of term matches the ‘positions’ metadata must be white-listed when building the index.

  this.ref('id')
  this.field('body')
  this.metadataWhitelist = ['position']

  documents.forEach(function (doc) { this.add(doc) }, this)
})

Does this package support this? In particularly I want to whitelist this.metadataWhitelist = ['position']

mikepspc avatar Dec 01 '20 22:12 mikepspc

any news on this?

gonpombo8 avatar Sep 16 '22 18:09 gonpombo8