Closed Rizky92 closed 1 year ago
Thanks @Rizky92
This seems to be because the closing tag does not have the same name so HTML Formatter used in blade-formatter is unable to find a matching tag.
To avoid this, Make sure to match the names of the starting and closing tags
<x-my-layout>
<x-slot:my-slot>
<div>My super cool content</div>
</x-slot:my-slot>
</x-my-layout>
The name of the closing tag itself seems to be arbitrary as long as there is a prefix of x-slot, so x-slot or colon prefixed x-slot:~ is fine.
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days
Context (Environment)
There is a new method sometime between laravel 8 and 9 that allow x-slot to suffix with parameter name using colon like
<x-slot:head>
. Because the formatter couldn't figure out which closing tag it belongs, the formatter does not handle the closing tag properly, thus resulting in something like this:Current Behavior
see image above
Expected Behavior
Steps to Reproduce
x-slot:property
.