Skip to content

Instantly share code, notes, and snippets.

View matthewowen's full-sized avatar

Matthew Owen matthewowen

View GitHub Profile
@matthewowen
matthewowen / raw_content.rb
Created November 6, 2012 15:39
access raw content in jekyll
module Jekyll
class RawContent < Generator
def generate(site)
site.posts.each do |post|
post.data['raw_content'] = post.content
end
end
{% for post in site.posts limit:5 %}
<li><span>{{ post.date | date_to_string }}:</span><a href="{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}