You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I installed prettier, on user I checked format on save and checked the config. Well it does not format on save I have followed all kinds of videos but it doesnot work. I think I did something wrong with the path. I even tried to uninstall it completely then reinstall it but no way. I can connect with my screen and help me I will be more than grateful.
Extension version: 10.4.0
VS Code version: Code 1.85.1 (Universal) (0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2, 2023-12-13T09:48:06.308Z)
OS version: Darwin arm64 23.4.0
Modes:
To fix the issue with Prettier not formatting on save in Visual Studio Code, you can follow these steps:
Check Prettier Configuration:
Make sure your Prettier configuration is set up correctly. Ensure that you have a valid prettier.config.js or .prettierrc file in your project root directory with the desired formatting rules.
Verify VS Code Settings:
Open your VS Code settings (settings.json) and confirm that the "editor.formatOnSave" setting is enabled. You can enable it by adding or updating the following line in your settings:
json
"editor.formatOnSave": true
Check for Conflicting Extensions:
Disable any other formatting extensions you have installed in VS Code temporarily to see if they might be conflicting with Prettier. Sometimes, multiple formatting extensions can interfere with each other.
Verify Prettier Extension Settings:
Ensure that the Prettier extension is properly configured in VS Code. Open the extensions view (Ctrl+Shift+X), search for "Prettier - Code formatter", and click on the gear icon to access its settings. Make sure that the "Format On Save" option is enabled.
Restart VS Code:
After making changes to settings or extensions, it's a good idea to restart VS Code to ensure that the changes take effect.
Check Output Panel for Errors:
Open the VS Code output panel (View -> Output) and select "Prettier" from the dropdown. Look for any error messages or warnings related to Prettier. These messages might provide insights into what's going wrong.
Reinstall Prettier Extension:
If none of the above steps resolve the issue, you can try reinstalling the Prettier extension. You mentioned that you've already tried this, but it's worth another attempt.
Verify Path Configuration (if relevant):
If you suspect that there's a path issue related to Prettier, double-check that the path to the Prettier executable is correctly configured in your VS Code settings. You can set the path explicitly using the "prettier.prettierPath" setting in your VS Code settings.
Type: Bug
I installed prettier, on user I checked format on save and checked the config. Well it does not format on save I have followed all kinds of videos but it doesnot work. I think I did something wrong with the path. I even tried to uninstall it completely then reinstall it but no way. I can connect with my screen and help me I will be more than grateful.
Extension version: 10.4.0
VS Code version: Code 1.85.1 (Universal) (0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2, 2023-12-13T09:48:06.308Z)
OS version: Darwin arm64 23.4.0
Modes:
System Info
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
A/B Experiments
The text was updated successfully, but these errors were encountered: