Open DanielStout5 opened 2 years ago
Also looking for unescape
.
Would Shopify take a PR to support unescape
as a filter? Looks pretty straightforward to add to https://github.com/Shopify/liquid/blob/master/lib/liquid/standardfilters.rb from https://docs.ruby-lang.org/en/2.2.0/CGI/Util.html
unescape would be great! so easy to implement too
I'd love to have this as well. Is someone working on it?
In my case, in section settings I want to include some <span>
elements in a richtext
field to add some styling. I can use a textarea
field instead, but then everything needs to be handwritten (bold, italics, links, etc).
We have HTML inside an order attribute we'd like to output in a Liquid template in Shopify - specifically it's in
order.attributes
.Just doing e.g.
{{ order.attributes.myHtmlVariable }}
is escaped - e.g. it outputs<
and>
How do we make Liquid output the variable without escaping? I've tried {% raw %} but that only disables the processing of Liquid tags themselves.
It's possible Shopify automatically encodes the contents of order.attributes - in that case, how can we unescape the HTML when outputting?