superstruct icon indicating copy to clipboard operation
superstruct copied to clipboard

Switch from Prettier & ESLint to Biome

Open yeoffrey opened this issue 7 months ago • 0 comments

TD;LR

Prettier and ESLint are slow and overly complicated for configuring formatting and linting. Biome offers a unified, simple tool for linting, formatting and organizing imports that outperforms Prettier and ESLint in speed as well.

Every rule that is enabled through the formatter and linter is one less thing for us to review in a PR, and makes our jobs easier.

Motivations

The linting rules in this project are looser than they should be. Superstruct requires a high-degree of reliability and that should be reflected in how we write the code in this package. Making the rules stricter benefits us from a development perspective so we don't write dangerous TypeScript, but also it's users to avoid unforeseen bugs.

Why Biome over ESLint and Prettier

Basically, just simplicity. One configuration to rule them all. Removes multiple development dependencies, is way faster... See more here.

Next Steps

This PR contains a Biome configuration that nearly matches our old configuration (except for some formatting in utils.ts). We should, one by one, re-enable these rules in separate PRs.

yeoffrey avatar Jul 27 '24 03:07 yeoffrey