---
layout: null
---
{
  {% for post in site.posts %}

    "{{ post.url | slugify }}": {
      "title": "{{ post.title | xml_escape }}",
      "url": " {{ post.url | prepend:site.baseurl | xml_escape }}",
      "tags": "{{ post.tags | xml_escape }}",
      "category": "{{ post.category | xml_escape }}"
    }
    {% unless forloop.last %},{% endunless %}
  {% endfor %}
}
---
layout: null
---
/**
 *	Jekyll is a static site generator and therefore does not have a database to query. Instead, we use this json file that is generated everytime to the site is built. (ex. jekyll build) This file contains every post with its associative metadata.
 */
{
  {% for post in site.posts %}

    "{{ post.url | slugify }}": {
      "title": "{{ post.title | xml_escape }}",
      "url": " {{ post.url | prepend:site.baseurl | xml_escape }}",
      "tags": [{% for tag in post.tags %} "{{ tag | xml_escape }}" {% if forloop.last == false %}{{ "," }}{% endif %}{% endfor %}],
      "category": "{{ post.category | xml_escape }}"
    }
    {% unless forloop.last %},{% endunless %}
  {% endfor %}
}
Create an array for tags.
Create an array for tags.
