A Liquid tag plugin for Jekyll that allows remote includes from external sources.
Add this line to your application's Gemfile:
group :jekyll_plugins do
gem 'jekyll-remote-include', :github => 'netrics/jekyll-remote-include'
end
And then execute:
$ bundle
Or install it yourself as:
$ gem install jekyll-remote-include
Then add the following to your site's _config.yml
:
plugins:
- jekyll-remote-include
š” If you are using a Jekyll version less than 3.5.0, use the gems
key instead of plugins
.
Use the tag as follows in your Jekyll pages, posts and collections:
{% remote_include https://raw.githubusercontent.com/jekyll/jekyll/master/README.markdown %}
or use with a liquid variable (eg. link from front matter):
{% if page.my_variable %}
{% remote_include {{ page.my_variable }} %}
{% endif %}
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)