rsnext/packages
Josh Goldberg ✨ fc52e02787
chore: enable typescript-eslint's recommended and stylistic configs internally (#52948)
Spinning out from #37151 and my draft PR #52845, this enables the two
basic recommended rulesets from
[typescript-eslint](https://typescript-eslint.io) for the Next.js
monorepo source code:

*
[`plugin:@typescript-eslint/recommended`](https://typescript-eslint.io/linting/configs#recommended):
Our base recommended rules that detect common bugs or _(non-stylistic)_
TypeScript bad practices
*
[`plugin:@typescript-eslint/stylistic`](https://typescript-eslint.io/linting/configs#stylistic):
Our base starting stylistic recommended for keeping codebases visually
consistent and avoiding out-of-practice visual constructs

The process I used is pretty standard (see
https://github.com/typescript-eslint/typescript-eslint/issues/6760 for
other repos it was done on):

1. Enable those base recommended presets
2. Remove any rule settings that are now redundant
3. Reconfigure any rule whose default settings didn't seem to make sense
for this codebase
4. Add a `// Todo: ...` comment, and under it, add a disable for any
rule that immediately reported a lot of complaints

Note that this only enables the presets internally. It doesn't impact
what end-users of published packages such as Next.js or
`create-next-app` experience. That's a separate task in #52845.

I also didn't fix any existing warning from the `canary` branch. Would
you like me to do that? My preference would be a separate PR to get it
in more quickly.

Any code changes are commented inline.

---------

Co-authored-by: Steven <steven@ceriously.com>
2023-07-31 16:32:54 -07:00
..
create-next-app v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
eslint-config-next v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
eslint-plugin-next chore: enable typescript-eslint's recommended and stylistic configs internally (#52948) 2023-07-31 16:32:54 -07:00
font v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
next chore: enable typescript-eslint's recommended and stylistic configs internally (#52948) 2023-07-31 16:32:54 -07:00
next-bundle-analyzer v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
next-codemod v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
next-env chore: enable typescript-eslint's recommended and stylistic configs internally (#52948) 2023-07-31 16:32:54 -07:00
next-mdx v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
next-plugin-storybook v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
next-polyfill-module v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
next-polyfill-nomodule v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
next-swc v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
react-dev-overlay v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
react-refresh-utils v13.4.13-canary.8 2023-07-31 20:06:20 +00:00
third-parties v13.4.13-canary.8 2023-07-31 20:06:20 +00:00