Page MenuHomePhabricator

[RN72] Remove deprecated ESLint formatting rules
ClosedPublic

Authored by ashoat on Jan 4 2024, 1:54 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Nov 9, 12:56 PM
Unknown Object (File)
Thu, Oct 31, 5:22 AM
Unknown Object (File)
Oct 5 2024, 7:29 PM
Unknown Object (File)
Oct 3 2024, 1:24 PM
Unknown Object (File)
Oct 3 2024, 1:24 PM
Unknown Object (File)
Oct 3 2024, 1:24 PM
Unknown Object (File)
Oct 3 2024, 1:24 PM
Unknown Object (File)
Oct 3 2024, 1:24 PM
Subscribers

Details

Summary

In ESLint 8.53, formatting rules are deprecated in favor of using Prettier for formatting.

D10538 updates us to 8.56.0, but the formatting rules won't be removed from ESLint until at least version 10. However, I figured now was as good a time as any to replace these rules.

We had three rules that are in the deprecated list. Of those, two of them aren't needed, since they're handled by Prettier: linebreak-style and semi.

We actually use max-len, however. Its use is explained in the comments of .eslintrc.json... basically, Prettier won't enforce limits on comment length.

ESLint's suggested migration path is to use @stylistic/eslint-plugin-js for this.

Depends on D10545

Test Plan

I edited a comment in a random JS file to be longer than 80 chars and confirmed that ESLint failed on it

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable