Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

Implement static-this rule (#4428) #4475

Merged
merged 11 commits into from Feb 25, 2019
Merged

Implement static-this rule (#4428) #4475

merged 11 commits into from Feb 25, 2019

Conversation

mbelsky
Copy link
Contributor

@mbelsky mbelsky commented Jan 21, 2019

PR checklist

Overview of change:

Implement static-this rule

Is there anything you'd like reviewers to focus on?

CHANGELOG.md entry:

[new-rule] static-this

@mbelsky
Copy link
Contributor Author

mbelsky commented Jan 21, 2019

There are two failed lint tests with the new rule. Should I replace this usage there?

Copy link
Contributor

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a good start!

Yes please to fixing the issues internally. It should be a little easier if you implement an auto-fixer 😉

src/rules/staticThisRule.ts Show resolved Hide resolved
test/rules/static-this/tslint.json Outdated Show resolved Hide resolved
test/rules/static-this/test.ts.lint Show resolved Hide resolved
@mbelsky
Copy link
Contributor Author

mbelsky commented Feb 6, 2019

Hey @JoshuaKGoldberg
I've did some work on the pr. Please review it again 🙏

Copy link
Contributor

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Getting there - a few comments on simplifying the implementation and error reporting, and some missing test cases.

src/rules/staticThisRule.ts Outdated Show resolved Hide resolved
test/rules/static-this/test.ts.lint Outdated Show resolved Hide resolved
test/rules/static-this/test.ts.lint Show resolved Hide resolved
test/rules/static-this/test.ts.lint Show resolved Hide resolved
test/rules/static-this/test.ts.lint Show resolved Hide resolved
src/rules/staticThisRule.ts Outdated Show resolved Hide resolved
src/rules/staticThisRule.ts Outdated Show resolved Hide resolved
src/rules/staticThisRule.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great, thanks @mbelsky! 🙌

Waiting on approval from @adidahiya or another palantirtech member to merge in, since this is a new rule.

Copy link
Contributor

@adidahiya adidahiya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @mbelsky 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants