vscode-blade-formatter
vscode-blade-formatter copied to clipboard
[Formatting Bug]: Laravel Blade anonymous component attributes are being formatted to use single quote when use blade directive
Platform
Windows
Template before formatting
<x-floating_input placeholder="{{ __('SKU') }}"
fieldName="variants[{{ $index }}][sku]" title="{{ __('SKU') }}"
iconClass="ti-barcode"
fieldErrorMessage='{{ $errors->first("variants.$index.sku") }}'
fieldValue='{{ old("variants.$index.sku", "") }}'
/>
Template after formatting
<x-floating_input placeholder="{{ __('SKU') }}"
fieldName="variants[{{ $index }}][sku]" title="{{ __('SKU') }}"
iconClass="ti-barcode"
fieldErrorMessage='{{ $errors->first("variants.$index.sku") }}'
fieldValue='{{ old("variants.$index.sku", '') }}'
/>
Expected Behaviour
As you can see when I pass the fieldValue in the double quote " automatically changed to ' causing the component cannot be rendered. It should remains the double quote for empty check passed in. I'm not sure it's conflicting with other plugins or the plugin itself bug.
Relevant log output
No response