Updating object properties in twig
Twig has a do tag that allows you to do that.
{% do foo.setBar(value) %}
You can do it by merging objects:
{% set object = object|merge({'property1': 'somenewvalue'}) %}
Twig has a do tag that allows you to do that.
{% do foo.setBar(value) %}
You can do it by merging objects:
{% set object = object|merge({'property1': 'somenewvalue'}) %}