Skip to content

Instantly share code, notes, and snippets.

@sskylar
Created October 19, 2017 19:34
Show Gist options
  • Save sskylar/aa692335ee8ce68282120ecf69d41cb9 to your computer and use it in GitHub Desktop.
Save sskylar/aa692335ee8ce68282120ecf69d41cb9 to your computer and use it in GitHub Desktop.
Add helper/description text next to a custom Jekyll field in Siteleaf
---
defaults:
- scope:
path: ''
type: posts # change scope type here
values:
header_image: "Should be 800x200 (JPG)"
{% comment %}
Optionally, you can validate presence of an image
{% endcomment %}
{% if page.header_image contains ".jpg" %}
<img src="{{ page.header_image }}">
{% endif %}
@sskylar
Copy link
Author

sskylar commented Oct 19, 2017

This field will show up in Siteleaf like so:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment