Open ajiho opened 11 months ago
https://github.com/VincentLanglet/Twig-CS-Fixer This could work.
Don't want to integrate prettydiff here like the vscode-twig-language-2 does because prettydiff itself is not well maintained (no code changes since 2019, only the readme.md updates).
I see that VincentLanglet/Twig-CS-Fixer fixes only Twig-related issues. We need something above it to also format HTML.
Hi there!
How about built-in HTML formatter? VS Code has perfect HTML support, HTML language server and Handlebars support.
settings.json:
{
"html.format.indentHandlebars": true,
"html.format.templating": true,
}
@vralle
VSCode-only solution is ok, but I'd rather add something that's editor-independent.
vsc uses js-beautify under the hood (code ref)
There is also an issue for Twig: https://github.com/beautifier/js-beautify/issues/991
This could work: https://github.com/zackad/prettier-plugin-twig-melody
First of all, thank you for this plugin,Because I spend most of my time writing HTML code, I think losing HTML intellisense would be very painful for me,And I habitually format the code (shift+alt+f), and vscode will prompt me that there is no formatting program,I don't want to go back to PHP Storm, so if there is a better development experience, I would like to get some advice from you