We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Any ideas why the HTML content won't render properly in my Popover component if I first store the value in a variable?
This does not work:
var popContent = '<strong>Holy guacamole!</strong> Check this info.'; var popover = <Popover title="Popover right">{popContent}</Popover>; return ( <OverlayTrigger trigger='click' rootClose placement='right' overlay={popover}> <Button bsStyle='xsmall'>Holy guacamole!</Button> </OverlayTrigger> );
Because it generates this:
While this does work:
var popover = <Popover title="Popover right"><strong>Holy guacamole!</strong> Check this info.</Popover>; return ( <OverlayTrigger trigger='click' rootClose placement='right' overlay={popover}> <Button bsStyle='xsmall'>Holy guacamole!</Button> </OverlayTrigger> );
Thanks -- I'm stumped!
The text was updated successfully, but these errors were encountered:
That's not the way JSX variables work. You'd want e.g.
var popContent = <span><strong>Holy guacamole!</strong> Check this info.</span>
Sorry, something went wrong.
Not sure why @taion reply got a downvote, that's exactly why the popup doesn't get the html styling, you need a jsx variable
No branches or pull requests
Any ideas why the HTML content won't render properly in my Popover component if I first store the value in a variable?
This does not work:
Because it generates this:
While this does work:
Thanks -- I'm stumped!
The text was updated successfully, but these errors were encountered: