Scenario: I want to integrate Prettier in our code base which is currently using ESLint (for .js and .scss both). The project is using gulp.
It doesn't feel quite right to me to use ESLint, I wonder if it would be better to use Stylelint or Sass Lint instead.
I completed integrating ESLint + Prettier, Planning to do the same with [ Stylelint || Sasslint || EsLint] + Prettier.
And have gulp 'fix' on file save (Watcher).
Any recommendation is appreciated.
Pura vida! Well, I had a similar issue and at the end I decided to use Stylelint + Prettier for that job, in our case, we wanted that our linting process includes the SCSS files and not only the JS file, base on that we concluded that using only ESLint to do both things wasn't the best option, so, we integrated prettier with Stylelint, and for that we used a neat plugin that allowed us to use Prettier inside Stylelint here is the link, https://github.com/prettier/stylelint-prettier#recommended-configuration, I hope that this can help you, hasta pronto!, :)
Thanks for commenting @Alexis,
Honestly, I did forget what I did at the end, so I just went back to see what was my decision...
and... yes Stylelint was the one.
In the case of .js files I would recommend using both Eslint and Prettier.
You can set up Prettier as an Eslint rule using the following plugin:
And in order to avoid conflicts between Prettier and Eslint, you can use this config:
Which turns off all Eslint rules that are unnecessary or might conflict with Prettier.