-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
search.json
46 lines (46 loc) · 1.64 KB
/
search.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
---
layout: null
---
[
{% for post in site.posts %}
{
"title" : "{{ post.title | strip_html | escape }}",
"desc" : "tags: {{ post.tags | join: ', ' | default: '(none)' }}",
"url" : "{{ site.baseurl }}{{ post.url }}",
"meta" : "Post: {{ post.date | date: '%B %-d, %Y'}}"
} {% unless forloop.last %},{% endunless %}
{% endfor %}
,
{% for page in site.html_pages %}
{
{%- unless page.url == "/"
or page.url == "/404.html"
or page.url == "/tags/"
or page.url == "/thank-you"
or page.url == "/plan/"
or page.url == '/search/' -%}
{% if page.title %}
"title" : "{{ page.title | strip_html | escape }}",
"desc" : "{{ page.excerpt | escape | default: page.title }}",
"url" : "{{ site.baseurl }}{{ page.url }}",
"meta" : "Page: {{page.url}}"
{% endif %}
{%- endunless -%}
} {% unless forloop.last %},{% endunless %}
{% endfor %}
,
{% assign principles = site.principles | sort: "principle_order" %}
{% for principle in principles %}
{%- if principle.principle_byline -%}
{%- assign principle_meta = principle.principle_byline | prepend: 'Principle: ' -%}
{%- else -%}
{%- assign principle_meta = 'Principle' -%}
{%- endif -%}
{
"title" : "{{ principle.title | strip_html | escape }}",
"desc" : "{{ principle.principle_byline | default: principle.title }}",
"url" : "{{ site.baseurl }}{{ principle.url }}",
"meta" : "{{ principle_meta }}"
} {% unless forloop.last %},{% endunless %}
{% endfor %}
]