Closed evrpress closed 9 months ago
This is with prettify: true
, right?
Yes, actually my settings is
prettify: {
useTabs: true,
}
but the result is the same
Yeah, it's a prettier
bug unfortunately, here's a reproduction.
Only way around it will be through a regex that corrects this, will add it to the backlog for the other issue with embeddedLanguageFormatting
, will fix them both in the next release.
Using parser: 'glimmer'
helps, but that removes the doctype
form the HTML, which is unacceptable.
Reported the issue in the prettier
repo: https://github.com/prettier/prettier/issues/15982
Thanks Cosmin, I think this issue is not critical. I will submit the issue to the correct repo next time. I'm still not sure which tool in Maizzle is responsible for what ๐
Donโt worry about it, I actually prefer knowing of something not working in Maizzle and then taking it upstream if needed :)
I use this line in afterTransformers
for now:
html = html.replaceAll(/<\/pre([\s\t]+)>/gi, '$1</pre>');
This also preserves any indention.
Yup, doing something similar now:
html.replace(/(<\/pre)\s+>/g, '$1>')
Should be fixed in v4.7.3
now ๐
Adding a
<pre>
tag with content in a component causes unexpected tabs in the closing tag.component.html
output
I think most clients render that just fine but we know how email clients may react.