Prettier includes the option htmlWhitespaceSensitivity to control how to handle breaking lines that contain tags that get rendered as inline by default. This plugin doesn't appear to respect that option, instead always breaking the inner content onto a separate line, which causes tags like to render links with trailing whitespace. Effectively, htmlWhitespaceSensitivity is always set to "ignore".
Example input:
<p>If you didn't receive an email, please check your spam folder or <a href="{{ path('app_forgot_password_request') }}">try again</a>.</p>
Actual output:
<p>
If you didn't receive an email, please check your spam folder or
<a href="{{ path('app_forgot_password_request') }}">
try again
</a>.
</p>
Expected output (htmlWhitespaceSensitivity: "css"):
<p>
If you didn't receive an email, please check your spam folder or
<a href="{{ path('app_forgot_password_request') }}"
>try again</a
>.
</p>
Expected output (htmlWhitespaceSensitivity: "strict"):
<p
>If you didn't receive an email, please check your spam folder or
<a href="{{ path('app_forgot_password_request') }}"
>try again</a
>.</p
>
Would it be possible to add support for this?
Prettier includes the option htmlWhitespaceSensitivity to control how to handle breaking lines that contain tags that get rendered as inline by default. This plugin doesn't appear to respect that option, instead always breaking the inner content onto a separate line, which causes tags like to render links with trailing whitespace. Effectively, htmlWhitespaceSensitivity is always set to "ignore".
Example input:
Actual output:
Expected output (htmlWhitespaceSensitivity: "css"):
Expected output (htmlWhitespaceSensitivity: "strict"):
Would it be possible to add support for this?