Added the eslint rule to help with import order and ran the fix - #3885
Conversation
Performance Report✔️ no performance regression detected Full benchmark results
|
| import * as block from "./block"; | ||
| import * as pool from "./pool"; | ||
| import * as state from "./state"; | ||
| import {RoutesData, ReturnTypes, reqEmpty, ContainerData} from "../../utils"; |
There was a problem hiding this comment.
So we actually want the closest modules at the bottom, so the correct order would be the original one. @dadepo can you try to tweak the rule to achieve that?
Codecov Report
@@ Coverage Diff @@
## master #3885 +/- ##
===========================================
+ Coverage 0 36.60% +36.60%
===========================================
Files 0 325 +325
Lines 0 8975 +8975
Branches 0 1407 +1407
===========================================
+ Hits 0 3285 +3285
- Misses 0 5547 +5547
- Partials 0 143 +143 |
|
Can we block this until we land ESM support? This will be a bit annoying for that PR by creating a bunch of confiicts. |
|
ready for rebase off master |
…conflict. Still new to review if the eslint works as before
|
tests still erroring |
|
I think I made conflicts with #4064 |
| get attnets(): BitArray { | ||
| return this._metadata.attnets; | ||
| } | ||
| set attnets(attnets: BitArray) { |
There was a problem hiding this comment.
Please preserve whitespace in all changes of this file. After each method and at least 1 new line
| return this.state === SyncState.Synced; | ||
| } | ||
|
|
||
| get state(): SyncState { |
There was a problem hiding this comment.
Why all this changes in a PR that's clearly scoped to "import order"? Could you please revert this commit and do this changes if applicable? We have really never followed the member-ordering rule in Lodestar
Motivation
In a previous PR it was pointed out that the preferred order for imports should be:
This PR enforces this via eslint to make it more applicable. It also updates existing import to adhere with the import rule