Merge pull request #2641 from cdr/send-ready-to-all-origins

Send 'loaded' event to all parent origins
This commit is contained in:
Dean Sheather 2021-01-27 05:52:13 +10:00 committed by GitHub
commit 1fcb0c3ddd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -102,7 +102,7 @@ export const initialize = async (services: ServiceCollection): Promise<void> =>
if (parent) {
// Tell the parent loading has completed.
parent.postMessage({ event: 'loaded' }, window.location.origin);
parent.postMessage({ event: 'loaded' }, '*');
// Proxy or stop proxing events as requested by the parent.
const listeners = new Map<string, (event: Event) => void>();