0.0
No commit activity in last 3 years
No release in over 3 years
Jekyll plugin for building sites using Fridge content
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.0

Runtime

>= 3.0
 Project Readme

jekyll-fridge

Jekyll helper for adding Fridge content to your Jekyll site.

Installation

  • Add jekyll-fridge to your Gemfile:
group :jekyll_plugins do
  gem "jekyll-fridge"
end
  • Read on to configure the plugin.

Not using Bundler? There are other ways..

Usage

In _config.yml

fridge:
  client_id: sk_xxxxxxxxxx
  client_secret: xxxxxxxxxxxx

In your templates

<h1>{{site.fridge.settings.home.title}}</h1>

<nav>
  {% for item in site.fridge.navigation.content %}
    <li>{{item.title}}</li>
  {% endfor %}
</nav>

{{site.fridge.content.15.body | markdownify }}

{% for posts in site.fridge.content.blog_post %}
  <li>Post: {{post.title}}</li>
{% endfor %}

Using Jekyll filters

{% assign firefoxes = site.fridge.browser.content | where:"title", "Firefox" %}
{% for browser in firefoxes %}
  <li>{{browser.title}}</li>
{% endfor %}

{% assign pages = site.fridge.content.page | sort:"title" %}
{% for page in pages %}
  <li>{{page.title}}</li>
{% endfor %}

Filters

fridge_asset

Finds Fridge asset based on file name. Downloads asset to asset_dir (configurable. defaults to assets) and returns a url for the file.

{% for image in site.fridge.content.photo %}
  <img src="{{ image.name | fridge_asset }}" />
{% endfor %}

fridge_choices

Parses choices from a select/radio/checkbox content type.

{% assign choices = site.fridge.types.blog.categories.choices %}
{% for category in choices %}
  {{category}}
{% endfor %}

Reference