Closed daniel-zahariev closed 7 months ago
Following the tutorial in this article i have formatted a Blade template which looks roughly like:
<!DOCTYPE html> <html> <head> <script src="https://cdn.tailwindcss.com"></script> <style type="text/tailwindcss"> @layer components { .btn { @apply rounded-full leading-4; color: white; } } </style> </head> <body> Hello </body> </html>
and the spaces after @layer and @apply were stripped and the file looks as follows post-formatting:
@layer
@apply
<!DOCTYPE html> <html> <head> <script src="https://cdn.tailwindcss.com"></script> <style type="text/tailwindcss"> @layercomponents { .btn { @applyrounded-full leading-4; color: white; } } </style> </head> <body> Hello </body> </html>
This completely breaks the Tailwind styling.
Expected behaviour would be that those spaces are not stripped.
Laravel: 11 prettier: 3.2.5 prettier-plugin-blade: 2.1.11 prettier-plugin-tailwindcss: 0.5.13
Thanks for the detailed information! This has been corrected, and the fix is available in version 2.1.12
2.1.12
Problem
Following the tutorial in this article i have formatted a Blade template which looks roughly like:
and the spaces after
@layer
and@apply
were stripped and the file looks as follows post-formatting:This completely breaks the Tailwind styling.
Expectation
Expected behaviour would be that those spaces are not stripped.
Software Versions
Laravel: 11 prettier: 3.2.5 prettier-plugin-blade: 2.1.11 prettier-plugin-tailwindcss: 0.5.13