Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork2.8k
fix(eslint-plugin): [member-ordering] ignore method overloading#10536
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Changes fromall commits
File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -2148,6 +2148,52 @@ interface Foo { | ||
| }, | ||
| ], | ||
| }, | ||
| { | ||
| code: ` | ||
| class Foo { | ||
| public baz(): void; | ||
| @Decorator() public baz() {} | ||
| @Decorator() bar() {} | ||
| } | ||
| `, | ||
| options: [ | ||
| { | ||
| default: ['public-decorated-method', 'public-instance-method'], | ||
| }, | ||
| ], | ||
| }, | ||
| { | ||
| code: ` | ||
| class Foo { | ||
| public bar(): void; | ||
| @Decorator() bar() {} | ||
| public baz(): void; | ||
| @Decorator() public baz() {} | ||
| } | ||
| `, | ||
| options: [ | ||
| { | ||
| default: ['public-instance-method', 'public-decorated-method'], | ||
| }, | ||
| ], | ||
| }, | ||
| { | ||
| code: ` | ||
| class Foo { | ||
| @Decorator() bar() {} | ||
| public baz(): void; | ||
| @Decorator() public baz() {} | ||
| } | ||
| `, | ||
| options: [ | ||
| { | ||
| default: ['public-instance-method', 'public-decorated-method'], | ||
| }, | ||
| ], | ||
| }, | ||
| ], | ||
| invalid: [ | ||
| { | ||
| @@ -4439,7 +4485,7 @@ abstract class Foo { | ||
| class Foo { | ||
| C: number; | ||
| [A: string]: number; | ||
| public static D() {} | ||
| static [B: string]: number; | ||
| } | ||
| `, | ||
| @@ -4471,7 +4517,7 @@ class Foo { | ||
| abstract class Foo { | ||
| abstract B: string; | ||
| abstract A(): void; | ||
| public C() {} | ||
ContributorAuthor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. This is probably a typo. The following TS error occurs because | ||
| } | ||
| `, | ||
| errors: [ | ||
| @@ -4623,7 +4669,7 @@ class Foo { | ||
| code: ` | ||
| class Foo { | ||
| A: string; | ||
| private C() {} | ||
| constructor() {} | ||
| @Dec() private B: string; | ||
| set D() {} | ||
| @@ -4975,7 +5021,7 @@ class Foo { | ||
| code: ` | ||
| class Foo { | ||
| A: string; | ||
| private C() {} | ||
| constructor() {} | ||
| private readonly B: string; | ||
| set D() {} | ||
| @@ -5267,6 +5313,29 @@ interface Foo { | ||
| }, | ||
| ], | ||
| }, | ||
| { | ||
| code: ` | ||
| class Foo { | ||
| static foo() {} | ||
| foo(): void; | ||
| foo() {} | ||
| } | ||
| `, | ||
| errors: [ | ||
| { | ||
| column: 3, | ||
| data: { | ||
| name: 'foo', | ||
| rank: 'public static method', | ||
| }, | ||
| line: 5, | ||
| messageId: 'incorrectGroupOrder', | ||
| }, | ||
| ], | ||
| options: [ | ||
| { default: ['public-instance-method', 'public-static-method'] }, | ||
| ], | ||
| }, | ||
| ], | ||
| }; | ||
Uh oh!
There was an error while loading.Please reload this page.