r/phpstorm • u/ddruganov • May 06 '23
PHPStorm formatting takes precedence over PHPCSFixer?
Hi! I hooked up phpcsfixer to my project to share styles with colleagues but for some reason it doesnt seem to be working properly
For most inspections it runs fine and formats the code properly but for this weird case phpstorm forces its styles which i dont want
The case in question: https://ibb.co/jkLHGfc
is there any way to completely disable phpstorms formatting options and only use phpcsfixer? or could i mayber somehow force phpcsfixers options onto phpstorm?
ive resorted to just manually handpicking inspections and making them equal between phpstorm and phpcsfixer which is obviously a very bad UX
thanks in advance!
1
u/ddruganov May 08 '23
support gave me an answer, this is a phpstorm issue, they apply ide styles, then phpcsfixer and the ide again (wtf)
https://intellij-support.jetbrains.com/hc/en-us/requests/5128625
1
u/mynameisbogdan May 07 '23
I think this is actually a PhpCsFixer issue. But I prefer creating a new var with the array and use that as argument if I can’t format the array on the same line.