bencodezen / vue-enterprise-boilerplate

An ever-evolving, very opinionated architecture and dev environment for new Vue SPA projects using Vue CLI.
7.77k stars 1.32k forks source link

Guidance on `*.vue` tooling autofix config : prettier + eslint + .vscode/settings.json #157

Closed madebycaliper closed 4 years ago

madebycaliper commented 5 years ago

Hey @chrisvfritz I'm a big fan of this project thank you!

I successfully used VEB for a project earlier this year, but trying to set it up from scratch again I've been having a hell of a time setting up vscode to format SFC *.vue files on save using the .eslintrc.js settings.

I have it working using the basic formatting with: "vetur.format.defaultFormatter.html": "prettier", added to my vscode settings.json but its not ideal, as it doesn't respect settings like PascalCase that I need for linting purposes.

I have the Vetur and Prettier extensions installed (tried this all with them disabled too), but after spending much of this Saturday trying every combination I could think of, I'm not sure which file to edit to ensure vscode will play nice and format according to the VEB ESlint settings.

Any tips or gotchas to lookout for? Thanks.

chrisvfritz commented 4 years ago

Apologies for the long delay in reply - it's been a really hectic summer. It sounds like you might be missing dbaeumer.vscode-eslint from .vscode/extensions.json. If that doesn't help, I'd be happy to help figure out what you're missing if you upload a project demonstrating the issue. 🙂

chrisvfritz commented 4 years ago

Closing for now, but happy to reopen if the last tip didn't help or someone else encounters the same issue. 🙂

madebycaliper commented 4 years ago

@chrisvfritz thanks for getting back to me! My summer was also pretty 🥜. I just double checked and I do have ESlint installed. Any other ideas as to why formatting wouldn't be triggered?