Prettier not formatting PHP Code #3184
Unanswered
StreakDragon
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm having an issue with Prettier not formatting my PHP code, it's working for everything else however (ie HTML, JS, CSS) .
I'm currently on Windows 11 pro.
I have PHP v8.2.11 currently installed and set up
I installed prettier via the Extensions Tab in VS Code
I ran npm install --global prettier @prettier/plugin-php
After I ran npm fund as instructed from the terminal
I set my formatter as Prettier under my language settings in VS Code.
When editing a PHP file prettier shows just a circle with a line through it () in the bottom right of VS Code (I assume that's the standard icon meaning it can't format the code). All other code (HTML, CSS, JS) shows a double check mark and formats properly.
I've looked at many articles online before coming here to try and figure this out. Any help would be greatly appreciated.
Beta Was this translation helpful? Give feedback.
All reactions