0
votes

Using JekyllRB/Rouge, how does one highlight (but not interpret) Liquid code within a markdown file?

IE:

I have a markdown file with:

Blah blah blah, my cool post... here's some code:

```liquid
{% assign variableName = 'test' %}
```

In the resulting HTML, I'd like to see the actual code, without Jekyll interpreting it within the markdown file.

1

1 Answers

1
votes

I figured it out.

Make use of the {% raw %} Liquid tag.

IE:

```
{% raw %}
  {{ somevariablewewanttoshow }}
{% endraw %}
```