Chrome v92 breaks alert / confirm for embedded apps

Just came across this ourselves.  The latest chrome update no longer allows alert() and confirm() dialogues from iframes / other domains - which in effect breaks these features for embedded Shopify Apps

Because this is now the default behavior I don't think there is a viable fix here except implementing an HTML confirmation dialogue yourself so I thought I would bring it to people's attention.

Based on some digging it seems like there might be one way Shopify could possibly fix this on their end.

Would Shopify be able to add sandbox attributes such as 'allow-modal' to the iframe that they load embedded apps in? 

See https://stackoverflow.com/questions/68492434/apps-script-alert-confirm-promote-does-not-work-any-lon...

An example of 'allow-modal' here: https://googlechrome.github.io/samples/block-modal-dialogs-sandboxed-iframe/

0 Likes