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

allow es6 class rule to be configured to discourage usage as well #359

Merged
merged 1 commit into from
Dec 13, 2015
Merged

allow es6 class rule to be configured to discourage usage as well #359

merged 1 commit into from
Dec 13, 2015

Conversation

pwmckenna
Copy link
Contributor

Doesn't change the default behavior, but allows you to specify 'never' as an option that recommends createClass over using es6 classes.

The argument for switching is still a little murky. In the meantime its nice to be able to force it in either case.

@yannickcr
Copy link
Member

Why not.

Maybe I'll rename this rule in next major version to be more explicit about the different styles.

yannickcr added a commit that referenced this pull request Dec 13, 2015
Add never option to prefer-es6-class rule
@yannickcr yannickcr merged commit 481ecbb into jsx-eslint:master Dec 13, 2015
@remitbri
Copy link

Documentation on the rule page needs an update

@remitbri
Copy link

Suggestion: in the nitpicking matter of [levelOfWarning, "value"] vs. [levelOfWarning, {key : "value"}], perhaps the rule could/should be [levelOfWarning, {"frequency" : "always/never"] ?

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

Successfully merging this pull request may close these issues.

None yet

3 participants