Permalink
Browse files

Add JSON Feed.

  • Loading branch information...
Vossy committed May 27, 2017
1 parent 1836cee commit 39f0f6942e9266d349806e5faffd9c13b95ea197
Showing with 22 additions and 1 deletion.
  1. +1 −1 _includes/footer.html
  2. +1 −0 _layouts/default.html
  3. +20 −0 feed.json
View
@@ -1,6 +1,6 @@
<div id="footer">
<div class="page">
<p id="atomlink"><a href="/atom.xml" title="Atom XML Feed">Subscribe - Atom XML</a></p>
<p id="atomlink">Subscribe - <a href="/atom.xml" title="Atom XML Feed">Atom XML</a> or <a href="/feed.json">JSON Feed</a></p>
<p>Comments, corrections, and anything else can be sent to <a href="mailto:justin@bleedingwolf.com">justin@bleedingwolf.com</a>.</p>
<p>Follow me on <a href="http://twitter.com/justinvoss" rel="me">Twitter</a>.</p>
</div>
View
@@ -26,6 +26,7 @@
<link rel="apple-touch-icon-precomposed" href="/apple-touch-icon-precomposed.png">
<link rel="alternate" type="application/atom+xml" href="/atom.xml">
<link rel="alternate" type="application/json" href="/feed.json" />
<meta name="author" value="Justin Voss">
View
@@ -0,0 +1,20 @@
---
---
{
"version": "https://jsonfeed.org/version/1",
"title": "Justin Voss",
"home_page_url": "http://justinvoss.com/",
"feed_url": "http://justinvoss.com/feed.json",
"icon": "http://justinvoss.com/apple-touch-icon-precomposed.png",
"items": [
{% for post in site.posts %}
{
"title": {{ post.title | jsonify }},
"date_published": "{{ post.date | date_to_xmlschema }}",
"id": "http://justinvoss.com{{ post.id }}",
"url": "http://justinvoss.com{{ post.url }}",
"content_html": {{ post.content | jsonify }}
} {% unless forloop.last %},{% endunless %}
{% endfor %}
]
}

0 comments on commit 39f0f69

Please sign in to comment.