Html option (data-html) is not working
See original GitHub issueHello there,
I am trying to render an html content for my tooltip using html prop but it is rendering an “object [Object]”.
Even with the commented line.
With a simple text as data-tip it is working correctly.
const Popover = ({ children, content, title, trigger }) => {
return (
<>
{React.cloneElement(children, {
'data-tip': <p>This is a test</p>,
'data-for': 'foo',
// 'data-html': true,
})}
<ReactTooltip id="foo" html />
</>
);
};
Can anyone help me? Did I miss something?
Thanks.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:7
Top Results From Across the Web
Select option not showing data after selected option
The mistake was at the #state function, I had another part of code which was waiting data for cities once the state was...
Read more >The HTML Option element - MDN Web Docs - Mozilla
The HTML element is used to define an item contained in a , an , or a element. As such, can represent menu...
Read more >HTML select disabled Attribute - W3Schools
The disabled attribute is a boolean attribute. When present, it specifies that the drop-down list should be disabled. A disabled drop-down list is...
Read more >Select not working - options not appearing on click
Hi, I am having trouble with the material select in my application. The element looks as if it is initializing as expected, however...
Read more >How to set the default value for an HTML <select> element
The select tag in HTML is used to create a dropdown list of options that can be selected. The option tag contains the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@LeoLetourneur @UnumIDAdmin Have you tried to add a
multiline
prop? In Options list there is a prop’s definition:I hope it will solve yout problem!
Hello,
I have a problem using
html=true
and<br>
. If I use<br>
, it displays “[Object, object], [Object, object]”. If I remove it, it’s fine.