Skip to content

Use double quote for transformed displayName #1708

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

Merged
merged 1 commit into from
Nov 4, 2014

Conversation

chenglou
Copy link
Contributor

JSX currently transforms everything to double quote except these two. This way, it's at least consistent and will satisfy half of the people who do put a strict quotation linting on their project.

Test: jest, check the double quoted transformed data-bla="something".

@jeffrifwald
Copy link

@chenglou There is also an issue with the quoteAttrName in the xjs.js transform file. The markup data-attr="testing" would be turned to 'data-attr' in the transformed source. So you will only pass linting if you don't have dashes in your element attributes. I have attempted to make that all configurable here: #1709

@chenglou
Copy link
Contributor Author

Cool! I'll leave this as a backup then. Will close once yours get merged.

@zpao
Copy link
Member

zpao commented Oct 31, 2014

We may move to recast before we ship another release but whatever. Want to rebase and do the quoteAttrName as well, then we'll merge this in?

JSX currently transforms everything to double quote except these two. This way, it's at least consistent and will satisfy half of the people who do put a strict quotation linting on their project.

Test: `jest`, check the double quoted transformed `data-bla="something"`.
@chenglou
Copy link
Contributor Author

Done.

zpao added a commit that referenced this pull request Nov 4, 2014
Use double quote for transformed `displayName`
@zpao zpao merged commit 4ba53e1 into facebook:master Nov 4, 2014
@chenglou chenglou deleted the displayName branch November 4, 2014 22:36
@zpao zpao added this to the 0.12.2 milestone Nov 26, 2014
zpao added a commit to zpao/react that referenced this pull request Dec 18, 2014
Use double quote for transformed `displayName`
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.

4 participants