18F / jekyll_pages_api_search

DEPRECATED - Jekyll search plugin based on lunr.js and jekyll_pages_api
https://rubygems.org/gems/jekyll_pages_api_search
Other
39 stars 8 forks source link

Duplicate search results appearing #34

Closed maya closed 8 years ago

maya commented 8 years ago

I'm getting the same set of results twice in my search results. I noticed this bc I saw it focusing on what I thought was a random result, but was actually the first result of the second duplication of results.

This is what it looks like:

screen_shot_2016-07-13_at_8 09 55_am_1024

This is my template code:


---
layout: default
header_border: true

---

<div class="usa-grid">
  {% jekyll_pages_api_search_interface %}
  {% jekyll_pages_api_search_results %}
</div>

{% jekyll_pages_api_search_load %}
maya commented 8 years ago

When I do not use the template above, and use what's default, I do not get duplicate results.

afeld commented 8 years ago

Turns out the search JS was being loaded twice on the site. Fixed in https://github.com/18F/beta.18f.gov/commit/e1d05b61c26d72953c62cbd346beedec5ab3f6e9.