This PR revamps the eslint-config-motley to use prettier alongside eslint-config-motley, to make coding ever faster while keeping the 🕶 styles.
Prettier is
an opinionated JavaScript formatter inspired by refmt with advanced support for language features from ES2017, JSX, and Flow. It removes all original styling* and ensures that all outputted JavaScript conforms to a consistent style.
Basically it modifies the code you wrote and makes it look even more pretty. It focuses on style, which has never been eslints strong part: for example eslint can never fix overly long lines automatically, but it can warn about them.
Because eslint-config-airbnb also does some things with the styles, we also enable https://github.com/prettier/eslint-config-prettier which disables all the style related rules. Instead the style errors are automatically fixed by lint-staged and husky when you are committing code in. Very nice!
With this PR, the script also configures .eslintrc.js and package.json for you, so it's pretty much zero configuration.
Installation is done by a simple script similar to eslint-config-airbnb, and this version is released as @next at the moment. If you want to try it, run
This PR revamps the
eslint-config-motley
to useprettier
alongsideeslint-config-motley
, to make coding ever faster while keeping the 🕶 styles.Prettier is
Basically it modifies the code you wrote and makes it look even more pretty. It focuses on style, which has never been
eslint
s strong part: for exampleeslint
can never fix overly long lines automatically, but it can warn about them.Because
eslint-config-airbnb
also does some things with the styles, we also enable https://github.com/prettier/eslint-config-prettier which disables all the style related rules. Instead the style errors are automatically fixed bylint-staged
andhusky
when you are committing code in. Very nice!With this PR, the script also configures
.eslintrc.js
andpackage.json
for you, so it's pretty much zero configuration.Installation is done by a simple script similar to
eslint-config-airbnb
, and this version is released as@next
at the moment. If you want to try it, runon your project folder containing
package.json