projectEndings / staticSearch

A codebase to support a pure JSON search engine requiring no backend for any XHTML5 document collection
https://endings.uvic.ca/staticSearch/docs/index.html
Mozilla Public License 2.0
46 stars 21 forks source link

Retain elements if weight is declared but is not a context #289

Closed joeytakeda closed 4 months ago

joeytakeda commented 4 months ago

Previously, if an element wasn't a context (e.g. a span without explicitly being set as a context), only its children were processed, which mean that spans with a weight attached were being dropped. This makes the conditional a bit more aware of the combinations that should make an element be retained.