-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfeed.json
24 lines (24 loc) · 1.1 KB
/
feed.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
---
layout: null
---
{% capture base_tag %}<base href="{{ "" | absolute_url }}">{% endcapture %}{
"version": "https://jsonfeed.org/version/1",
"title": {{ site.title | jsonify }},
"home_page_url": {{ "" | absolute_url | jsonify }},
"feed_url": {{ "/feed.json" | absolute_url | jsonify }},
"description": {{ site.description | jsonify }},
"icon": {{ site.logo | absolute_url | jsonify }},
"author": { "name": {{ site.author | jsonify }}},
"items": [ {% assign my_posts = site.posts | where_exp: "p", "p.is_listed" | sort: 'date' | reverse %}{% for post in my_posts limit:32 %} {
"id": {{ post.id | jsonify }},
"url": {{ post.url | absolute_url | jsonify }},
"title": {{ post.title | jsonify }},
"content_html": {{ post.content | prepend: base_tag | jsonify }},
"summary": {{ post.excerpt | strip_html | strip_newlines | jsonify}},
"date_published": {{ post.date | date_to_xmlschema | jsonify }},{% if post.updated %}
"date_modified": {{ post.updated | date_to_xmlschema | jsonify }},{% endif %}
"tags": {{ post.tags | jsonify }}
}{% if forloop.last == false %},{% endif %}
{% endfor %}
]
}