Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore: update to use ES6 classes (refs #7849) #7891

Merged
merged 3 commits into from Jan 11, 2017

Conversation

qlaire
Copy link
Contributor

@qlaire qlaire commented Jan 10, 2017

What is the purpose of this pull request? (put an "X" next to item)

[ ] Documentation update
[ ] Bug fix (template)
[ ] New rule (template)
[ ] Changes an existing rule (template)
[ ] Add autofixing to a rule
[ ] Add a CLI option
[ ] Add something to the core
[ x ] Other, please explain:

What changes did you make? (Give an overview)
Update constructor functions to use ES6 classes. Also, changed one constructor function (rule-fixer.js) to a plain object since it does not have any internal state.

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

@jsf-clabot
Copy link

jsf-clabot commented Jan 10, 2017

CLA assistant check
All committers have signed the CLA.

@mention-bot
Copy link

@qlaire, thanks for your PR! By analyzing the history of the files in this pull request, we identified @IanVS, @mysticatea and @nzakas to be potential reviewers.

@eslintbot
Copy link

LGTM

@qlaire qlaire mentioned this pull request Jan 10, 2017
16 tasks

RuleFixer.prototype = {
constructor: RuleFixer,
const ruleFixer = {
Copy link
Member

@gyandeeps gyandeeps Jan 10, 2017

Choose a reason for hiding this comment

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

We might want to freeze this object so that we are consistent with what we had previously.

Copy link
Member

@kaicataldo kaicataldo left a comment

Choose a reason for hiding this comment

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

One tiny nitpick, but this is looking good. Thanks for contributing!


constructor: Registry,
/**
* @param {rulesConfig} [rulesConfig] Hash of rule names and arrays of possible configurations
Copy link
Member

Choose a reason for hiding this comment

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

Nitpick: Can we get rid of the extra whitespace after @param?

@not-an-aardvark not-an-aardvark added the chore This change is not user-facing label Jan 10, 2017
@eslintbot
Copy link

LGTM

@qlaire
Copy link
Contributor Author

qlaire commented Jan 10, 2017

@gyandeeps @kaicataldo thanks so much for reviewing! I've made the two changes you suggested.

@gyandeeps gyandeeps added accepted There is consensus among the team that this change meets the criteria for inclusion core Relates to ESLint's core APIs and features labels Jan 10, 2017
Copy link
Member

@kaicataldo kaicataldo left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for contributing!

@kaicataldo
Copy link
Member

Leaving this open a little bit longer so that we can get a few more pairs of eyes on this.

@ilyavolodin
Copy link
Member

LGTM. Thanks for contributing!

@ilyavolodin ilyavolodin merged commit 075ec25 into eslint:master Jan 11, 2017
@eslint-deprecated eslint-deprecated bot locked and limited conversation to collaborators Feb 6, 2018
@eslint-deprecated eslint-deprecated bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Feb 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
accepted There is consensus among the team that this change meets the criteria for inclusion archived due to age This issue has been archived; please open a new issue for any further discussion chore This change is not user-facing core Relates to ESLint's core APIs and features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants