Example Jekyll site using Contentful.com
This is a minimal example of a jekyll site using the jekyll-contentful gem to pull content from contentful.com at build time.
The example also demos the i18n features of the gem.
Running the example
At contentful.com
- Create a contentful.com account and a space (if you don't have one already)
- Add a the "de-DE" locale to the space (Settings -> Locales)
- Create a content type "Article".
- Add a short text field with the ID "title" to the content type. Make sure to check "This field represents the Entry title" and "enable localization of this field" on the field's settings page.
- Add a long text field with the ID "body". Check the checkbox "enable localization of this field" on the field's settings page.
- Create at least one entry (better more, and preferably translate them as well)
On your machine
- Clone the repo and
cd
into the folder
- Change
_config.yml
to include your Contentful API keys, Space ID, Content Type ID
- Run
bundle install
to install the dependencies
- Run
bundle exec jekyll serve -w
to build and serve the site
- Visit http://127.0.0.1:4000 to view the site you just built.