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

feat(new-rule-option): improve strict-boolean-expressions by adding allow-enum #3604

Conversation

atsu85
Copy link
Contributor

@atsu85 atsu85 commented Dec 22, 2017

PR checklist

Overview of change:

Added new configuration option "allow-enum", that disables errors when using enum in boolean expression, so that error wouldn't be emitted

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

I've added the motivation and detailed description to the issue #3571 - take a look at that as well.

I had 2 ideas to avoid emitting enum related errors:

This PR addresses that issue using approach b described in that issue.

CHANGELOG.md entry:

[new-rule-option] strict-boolean-expressions adds allow-enum to allow using enums in boolean expressions

… `allow-enum` rule option to disable warnings in case of using enum in boolean expression

closes palantir#3571
@palantirtech
Copy link
Member

Thanks for your interest in palantir/tslint, @atsu85! Before we can accept your pull request, you need to sign our contributor license agreement - just visit https://cla.palantir.com/ and follow the instructions. Once you sign, I'll automatically update this pull request.

@atsu85
Copy link
Contributor Author

atsu85 commented Jan 9, 2018

@ajafff, @adidahiya could You review this PR?

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.

3 participants