Skip to content

Modernize the lint and format toolchain (eslint, prettier, solhint) #4214

Description

@mswilkison

Both packages are several majors behind on everything that lints or formats:

Package random-beacon ecdsa Current
eslint ^7.32.0 ^7.32.0 10.8.0 — long past EOL
prettier ^2.4.1 ^2.5.1 3.9.6
solhint ^3.3.6 ^3.3.6 6.2.3
prettier-plugin-solidity ^1.0.0-beta.18 ^1.0.0-beta.19 2.3.1 — four-year-old beta

Probably three PRs rather than one, since the costs differ:

  • eslint 7 → 10 crosses the flat-config break at 9, and @thesis-co/eslint-config (a git tarball) has to come along. This is the real work.
  • prettier 2 → 3 reformats both trees. Best as its own commit containing nothing else, so review is git diff --stat. Note prettier 3 changed the default trailingComma to "all".
  • solhint 3 → 6 plus solhint-config-keep, also a git tarball.

Both packages currently pass lint with 0 errors and a pile of warnings (18 + 13 in random-beacon, 103 + 9 in ecdsa). Worth deciding whether to fix or formally accept those while in here.

Same work in tbtc-v2: threshold-network/tbtc-v2#1077.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions