Yqnn / svg-path-editor

Online editor to create and manipulate SVG paths
https://yqnn.github.io/svg-path-editor/
Apache License 2.0
4.11k stars 335 forks source link

Meta: Turn off format on save VS Code #130

Open justingolden21 opened 6 months ago

justingolden21 commented 6 months ago

Hi, I'm trying to contribute and learn my way around the project a little, but when I use VS code and save, it auto formats the entire file, causing hundreds of lines of diff, which of course I don't want to add to a messy PR for you.

I have "format on save" off in my settings, and in your .vscode folder I don't see anything that would cause this, you don't seem to have any prettier config and your eslint config doesn't have anything for it either. Even temporarily deleting your eslint config doesn't prevent it from formatting on save, and restarting VS code didn't work either.

The weird thing is, disabling eslint extension, disabling prettier extension, deleting eslint config and restarting VS Code STILL didn't prevent it from formatting hundreds of lines when I save the file...

image

image

I even tried adding:

"editor.formatOnSave": false,
"editor.codeActionsOnSave": {
    "source.fixAll": false,
    "source.fixAll.eslint": false
}

to my settings.json and following other steps on this stack overflow post with no luck...

I just tested and I don't have it formatting on save in any other project, which is why I figured it's specific to this one.

For now I'm using ktrl+k ctrl+shift+s, but I was wondering if you have some config somewhere deep I can't find that causes this project to format on save, as I don't encounter this problem in any other repo.

Thanks in advance.

justingolden21 commented 6 months ago

Specifically, the file app.component.html gets a big diff.

Yqnn commented 6 months ago

Weird. On my side I have both ESLint and Prettier installed and enabled, and my files are not auto-formatted on save. Did you also check the global settings.json file ?

justingolden21 commented 6 months ago

Weird. On my side I have both ESLint and Prettier installed and enabled, and my files are not auto-formatted on save. Did you also check the global settings.json file ?

You mean my personal global settings json in vs code right? Yeah I did. Super bizarre and I tried restarting and everything. Using ctrl+k ctrl+shift+s isn't the end of the world, and maybe it'll work next time I try lol, since I was only trying on that one day.