trivago / prettier-plugin-twig-melody

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

trailingComma option #57

Open urbantrout opened 4 years ago

urbantrout commented 4 years ago

It would be nice if this plugin would honor the trailingComma option in prettierrc. This wouldn't mess with git blame when you add a new property to an object.

Input:

{% set var = {
  id: 1,
  name: 'my-var'
} %}

Output:

{% set var = {
  id: 1,
  name: 'my-var'
} %}

Expected output

{% set var = {
  id: 1,
  name: 'my-var',
} %}
urbantrout commented 4 years ago

btw, thanks for this plugin. It really improved since I first started using it!