olivernn / lunr.js

A bit like Solr, but much smaller and not as bright
http://lunrjs.com
MIT License
8.87k stars 546 forks source link

Position metadata missing for matches from a collection #499

Open dxp227 opened 3 years ago

dxp227 commented 3 years ago

Hey there!

It looks like position metadata is missing for matches that occur within a collection-type field.

Example Fiddle

Not sure how this could be elegantly represented - perhaps by including the element index in the position data? eg. { "position": [ index, matchStart, matchLength ] }