echo
Outputs an expression.
Using the echo tag is the same as wrapping an expression in curly brackets ({{ and }}). However, unlike the curly
bracket method, you can use the echo tag inside liquid tags.
Tip
You can use filters on expressions inside echo tags.
Tip:
You can use filters on expressions inside echo tags.
Tip: You can use <a href="/docs/api/liquid/filters">filters</a> on expressions inside <code>echo</code> tags.
Syntax
{% liquid
echo expression
%}
expression
The expression to be output.
{% echo product.title %}
{% liquid
echo product.price | money
%}
Code
{% echo product.title %}
{% liquid
echo product.price | money
%}Data
{
"product": {
"price": "10.00",
"title": "Health potion"
}
}Output
Health potion
$10.00
Output
Health potion
$10.00Was this page helpful?