log

The log tag generates a log object.

Syntax

This tag has several usage styles, each style resulting in a valid action object.

Block syntax

Liquid
JSON
Liquid
{% log %}
{
"foo": "bar"
}
{% endlog %}
JSON
{
"log": {
"foo": "bar"
}
}

Tag syntax, single argument

Liquid
JSON
Liquid
{% log "foobar" %}
JSON
{
"log": "foobar"
}

Tag syntax, mapped arguments

Liquid
JSON
Liquid
{% assign details = hash %}
{% assign details["foo"] = "bar" %}
{% log message: "Something to remember", details: details %}
JSON
{
"log": {
"message": "Something to remember",
"details": {
"foo": "bar"
}
}
}