Open hirenreshamwala opened 1 year ago
Hi,
I want to add/remove web component on demand in my HTML file.
I created a component <demo-button>
<demo-button>
//Add document.body.append('<demo-button id="button1">'); //Remove document.body.removeChild(document.getElementById('button1'))
This code is adding my component and removing it properly but it shows the following error in the console
Warning: unmountComponentAtNode(): The node you're attempting to unmount was rendered by another copy of React.
some forum says I need to unmount it from the react component. But I don't know exactly what I need to do.
Can anyone guide me?
Thanks.
Hi,
I want to add/remove web component on demand in my HTML file.
I created a component
<demo-button>
This code is adding my component and removing it properly but it shows the following error in the console
some forum says I need to unmount it from the react component. But I don't know exactly what I need to do.
Can anyone guide me?
Thanks.