How to render Handlebars markup from a Liquid temp

2019-04-04 09:30发布

问题:

I am using Jekyll for our blog and rendering Handlebars templates is a pain. We have to escape like so:

{% highlight html %}
  <div>{{"{{code"}}}}</div>
{% endhighlight %}

It's fugly. Is there an easier way to do this?

回答1:

I found the answer:

{% highlight html %}
{% raw %}
  <div>{{code}}</div>
{% endraw %}
{% endhighlight %}