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

New rule: jsx-curly-brace-presence #196

Merged
merged 14 commits into from Mar 28, 2019

Conversation

OlafMerkert
Copy link
Contributor

Closes #149

Implements a new rule with option to either enforce or forbid curly braces around string literals.
Auto-Fix included.

@palantirtech
Copy link
Member

Thanks for your interest in palantir/tslint-react, @OlafMerkert! 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.

@peterchappy
Copy link

@OlafMerkert want to sign the CLA ? 🙏

@OlafMerkert
Copy link
Contributor Author

I already signed the CLA, the Quality gate for that passes. I suppose it needs to be reviewed and approved by a maintainer?

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.

lgtm otherwise

src/rules/jsxCurlyBracePresenceRule.ts Outdated Show resolved Hide resolved
src/rules/jsxCurlyBracePresenceRule.ts Outdated Show resolved Hide resolved
@OlafMerkert
Copy link
Contributor Author

@adidahiya Thank you for reviewing!

@adidahiya adidahiya self-assigned this Mar 17, 2019
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.

it's pretty close. you seem to have mixed array and object options syntaxes

src/rules/jsxCurlyBracePresenceRule.ts Outdated Show resolved Hide resolved
src/rules/jsxCurlyBracePresenceRule.ts Outdated Show resolved Hide resolved
test/rules/jsx-curly-brace-presence/always/tslint.json Outdated Show resolved Hide resolved
test/rules/jsx-curly-brace-presence/never/tslint.json Outdated Show resolved Hide resolved
adidahiya and others added 5 commits March 27, 2019 20:44
Co-Authored-By: OlafMerkert <olaf@m-merkert.de>
Co-Authored-By: OlafMerkert <olaf@m-merkert.de>
Co-Authored-By: OlafMerkert <olaf@m-merkert.de>
Co-Authored-By: OlafMerkert <olaf@m-merkert.de>
@adidahiya adidahiya merged commit d229c84 into palantir:master Mar 28, 2019
@OlafMerkert OlafMerkert deleted the jsx-curly-brace-presence-rule branch April 28, 2019 19:40
@b-fett
Copy link

b-fett commented May 26, 2019

@adidahiya make release with this one please)

@adidahiya
Copy link
Contributor

@b-fett I'll make a release this week... note that in the meantime, you can install an NPM package from a git branch (like this repo's master branch)... https://medium.com/@jonchurch/use-github-branch-as-dependency-in-package-json-5eb609c81f1a

@b-fett
Copy link

b-fett commented Sep 5, 2019

@adidahiya thanks for response.

Unfortunately this post is not relevant. Since library written in Typescript, it needs to be compiled before use, not just add to package.

@adidahiya
Copy link
Contributor

@b-fett just released 4.1.0, please try it out

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

Successfully merging this pull request may close these issues.

New rule: jsx-curly-brace-presence
5 participants