plugin-php icon indicating copy to clipboard operation
plugin-php copied to clipboard

Bug on Attributes!

Open siMobin opened this issue 5 months ago • 0 comments

@prettier/plugin-php v0.23.0 Playground link

Input:

<?php
new
#[Lazy]
#[Computed] 
#[Title('Staff')]
class extends Component {
    public $editing = [];
    public $branches;
};

Output:

<?php
new #[Lazy] #[Computed] #[Title("Staff")] class extends Component {
    public $editing = [];
    public $branches;
};

I tried to figure out how to fix this broken attribute formatting, but I couldn't find any information about it.

siMobin avatar Jul 15 '25 15:07 siMobin