vscode-blade-formatter icon indicating copy to clipboard operation
vscode-blade-formatter copied to clipboard

[Formatting Bug]: Functioncalls get's messed up

Open rabol opened this issue 6 months ago • 1 comments

Platform

MacOS

Template before formatting

<div>
    {{--  This get's messed up --}}
    <flux:profile :initials="auth()->user()->initials()"
                  icon-trailing="chevron-down" />


    {{--  This works fine --}}
    <flux:profile initials="{{auth()->user()->initials()}}"
                    icon-trailing="chevron-down" />
  
</div>

Template after formatting

<div>
    {{--  This get's messed up --}}
    <flux:profile :initials="auth() - > user() - > initials()"
                  icon-trailing="chevron-down" />


    {{--  This works fine --}}
    <flux:profile initials="{{ auth()->user()->initials() }}"
                  icon-trailing="chevron-down" />

</div>

Expected Behaviour

that this

:initials="auth()->user()->initials()"

does not get changed to this:

:initials="auth() - > user() - > initials()"

Relevant log output

<div>
    {{--  This get's messed up --}}
    <flux:profile :initials="auth() - > user() - > initials()"
                  icon-trailing="chevron-down" />


    {{--  This works fine --}}
    <flux:profile initials="{{ auth()->user()->initials() }}"
                  icon-trailing="chevron-down" />
</div>

rabol avatar May 25 '25 06:05 rabol

the formatting is actually wrong on all :parameter=""

<flux:navlist.item icon="home"
                                       :href="route('admin.index')"
                                       :current="request() - > routeIs('admin.index')">Dashboard</flux:navlist.item>
                </flux:navlist.group>

look at the :current

rabol avatar May 25 '25 06:05 rabol

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

github-actions[bot] avatar Jul 25 '25 02:07 github-actions[bot]

@rabol sorry for late reply. This issue has been fixed at v0.25.0. Please upgrade to latest version.

shufo avatar Jul 25 '25 05:07 shufo