You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Event delegation (target) doesn't really play nicely with React (the nature of React prefers encapsulated components) since it relies on the DOM for individual content too, but if you really want to use it, it still requires a child (it's used as the "delegate" parent wrapper which has the bubbling events attached to it).
importReact,{Component}from"react";importTippyfrom"@tippy.js/react";import"tippy.js/dist/tippy.css";import"./App.css";classAppextendsComponent{render(){return(<divclassName="App"><headerclassName="App-header"><Tippycontent="Yaay works"target=".target"><div>{/* the parent wrapper which gets the event listeners */}<divclassName="target">Testing</div><divclassName="target"data-tippy-content="Individual content">Testing</div><divclassName="target">Testing</div></div></Tippy></header></div>);}}exportdefaultApp;
I am not able to add a target property to Tippy.
TypeScript has children property set to required but the native library also supports a target element.
Am I missing something here?
The text was updated successfully, but these errors were encountered: