diff --git a/packages/asc-web-common/utils/index.js b/packages/asc-web-common/utils/index.js index 25b9b5a37e..3448768fe3 100644 --- a/packages/asc-web-common/utils/index.js +++ b/packages/asc-web-common/utils/index.js @@ -391,3 +391,13 @@ export function assign(obj, keyPath, value) { } obj[keyPath[lastKeyIndex]] = value; } + +export const frameCallback = (data) => { + window.parent.postMessage( + JSON.stringify({ + type: "onMethodReturn", + methodReturnData: data, + }), + "*" + ); +};