pages-gem icon indicating copy to clipboard operation
pages-gem copied to clipboard

Please add Liquify plugin to Github Pages.

Open lukepighetti opened this issue 6 years ago • 7 comments

Liquify parses liquid contained in your markdown files.

<div class="content">
  {{ topic.content | markdownify | liquify}}
</div>

It is a very powerful way to generate static Jekyll sites, as you can use HTML + liquid for templating, Markdown for text, and your _config.yml file for global variables, and have them available for use in Markdown. This allows you to have key things like website links, download links, contained in one location and never repeated.

https://github.com/vividh/liquify

Cheers

lukepighetti avatar Aug 05 '18 20:08 lukepighetti

Jekyll already uses "Liquid", see here. Maybe this is what you are searching for.

If you want to store data (like links or constants for example), you could use Data Files, which is already supported too.

If you want to recursively parse source files, you could use Includes.

It could also be that I understood the request wrongly. I just wanted to help you find a solution.

MaxValue avatar Oct 19 '18 17:10 MaxValue

Hi, thanks for the message.

Liquify is a Jekyll plugin that is not included with Github Pages that parses Liquid that is contained within Markdown. This is not possible with Github Pages currently as far as I know. This is outside the scope of Jekyll's built in Liquid parsing.

lukepighetti avatar Oct 19 '18 17:10 lukepighetti

Oh! This is possible! I use it myself! This is actually the core feature of Jekyll.

For example this Markdown file (which uses Liquid logic and variables) gets interpreted by GitHub into this site.

MaxValue avatar Oct 19 '18 19:10 MaxValue

Luke may be referring to a couple of plugins that extend how Liquid is processed in Jekyll. For instance, by recursively processing Liquid tags (sometimes Liquid in the files included with Liquid isn't processed), or allowing Liquid in page frontmatter.

arthurattwell avatar Oct 19 '18 20:10 arthurattwell

by recursively processing Liquid tags

I see. I thought so too in the beginning, that's why I mentioned Includes. They kinda allow embedding of Markdown file within Markdown file within Markdown file, but not recursively (I tried so myself, it just upsets the Liquid parser, recursion depth yaddayadda).

or allowing Liquid in page frontmatter

So basically templating the page front matter.

Ok now I think I have understood what this is about. Could be cool to have :)

You can probably achieve what you want by changing how your site is configured (e.g. using defaults and collections (with defaults)) which could be a workaround for the templated front matter.

Recursion sounds cool, but I guess we would need a good usage example to convince the GitHub guys to install this.

Another way to get this into GitHub Pages would be by simply asking the Liquid developers (or helping them) to implement similar features and then waiting for GitHub to update their Liquid version :P

MaxValue avatar Oct 19 '18 20:10 MaxValue

Yes, this is about putting liquid tags in the front-matter.

There is a list of plugins available to GitHub pages and they say to make a feature request if you want one added. This is a feature request for adding https://github.com/vividh/liquify to GitHub pages so that we can process liquid in our front matter.

Liquid team has no control over this.

lukepighetti avatar Oct 21 '18 14:10 lukepighetti

Would be great to have it included in default plugins for gh-pages

char0n avatar Jun 27 '21 08:06 char0n