sdk
sdk copied to clipboard
Allow tonconnect/ui to be created twice
trafficstars
Currently every time TonConnectUI initialized it tries to add to customElements and when application changes pages and initialized second time it throws an error
Uncaught DOMException: Failed to execute 'define' on 'CustomElementRegistry': this name has already been used with this registry
I added condition to check if customElements exists.
Not sure, but probably should fix #171 Tested in Solidjs app.
@thekiba rebased on main branch. Should be okay now.