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
CurrentSite: fix loading state. #1609
Conversation
{ hasOneSite | ||
? this.addNewWordPressButton() | ||
: <span className="current-site__switch-sites" /> | ||
: <span className="current-site__switch-sites"> </span> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't React render this as plain-text
? Should this be a space character
instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's rendering it fine for me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aduth you can insert HTML entities within literal text in JSX, the problem is if you wrap it in { }
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, upon double-checking the docs, @mtias is right and this only affects dynamic content - https://facebook.github.io/react/docs/jsx-gotchas.html#html-entities
Before:
After: