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
Code for rendering a simple banner (without useEffect or useState) on the thank you page
import{reactExtension,View,Banner}from'@shopify/ui-extensions-react/checkout';exportdefaultreactExtension('purchase.thank-you.block.render',()=><Extension/>,);functionExtension(){console.log(`render extension at ${Date.now()}`);return<View><Bannerstatus="critical"title="My extension"/></View>;}
Position and save the extension on the thank you page in the editor. UI has only one banner as expected, but we can see console.log has been executed twice.
The same thing happens on the actual Thank you page.
Expected behavior
console.log should only execute once.
Screenshots
Additional context
The text was updated successfully, but these errors were encountered:
eric-he-rokt
changed the title
Checkout UI extension has been rendered twice in both editor and actual thank you page
Checkout UI extension has been executed twice in both editor and actual thank you page
Oct 12, 2023
Please list the package(s) involved in the issue, and include the version you are using
"@shopify/ui-extensions": "2023.10.0",
"@shopify/ui-extensions-react": "2023.10.0",
Describe the bug
Steps to reproduce the behavior:
console.log
has been executed twice.Expected behavior
console.log
should only execute once.Screenshots
Additional context
The text was updated successfully, but these errors were encountered: