aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorXhmikosR <[email protected]>2015-12-05 10:18:18 +0200
committerXhmikosR <[email protected]>2015-12-05 11:30:27 +0200
commit3afdbe426f7d195912777b8b55bec5db982f92e1 (patch)
tree325242a582fec38da2a806ce6a6d2fa4c7e2b168 /docs
parent4e7c7f4b9dfc3b2013b13aed77242b74335b1d26 (diff)
downloadbootstrap-3afdbe426f7d195912777b8b55bec5db982f92e1.tar.xz
bootstrap-3afdbe426f7d195912777b8b55bec5db982f92e1.zip
Fix docs/search.json.
* only loop through `html_pages` * skip pages without a title * stop double escaping the title; use Jekyll's `jsonify` filter to output valid JSON * remove `date` since we don't use it [skip sauce]
Diffstat (limited to 'docs')
-rw-r--r--docs/search.json12
1 files changed, 7 insertions, 5 deletions
diff --git a/docs/search.json b/docs/search.json
index a31fc7334..7cd8517bc 100644
--- a/docs/search.json
+++ b/docs/search.json
@@ -3,11 +3,13 @@
---
[
- {% for page in site.pages %}
+{% assign sorted_pages = site.html_pages | sort: 'title' %}
+{% for page in sorted_pages %}
+ {% if page.title %}
{
- "title" : "{{ page.title | escape }}",
- "url" : "{{ site.baseurl }}{{ page.url }}",
- "date" : "{{ page.date }}"
+ "title" : {{ page.title | jsonify }},
+ "url" : "{{ site.baseurl }}{{ page.url }}"
} {% unless forloop.last %},{% endunless %}
- {% endfor %}
+ {% endif %}
+{% endfor %}
]