trivago / prettier-plugin-twig-melody

Code formatting plugin for Prettier which can handle Twig/Melody templates
Apache License 2.0
157 stars 35 forks source link

Formatting macro with default arguments throws error #42

Open spider-mane opened 4 years ago

spider-mane commented 4 years ago

i get ERROR: Expected comma or ")" when attempting to format a macro with default parameter values such as

{% macro name(name = 'John') %}
  <h1>{{ name }}</h1>
{% endmacro %}

It's followed by The argument list of a macro can only consist of parameter names separated by commas.

Is this a mistake? Default arguments are valid after all.

FNGR2911 commented 2 years ago

Same error here. Is there any way to ignore it?