zeplin / storybook-zeplin

Storybook addon to view Zeplin resources in story panel
https://storybook-zeplin.netlify.app
MIT License
115 stars 16 forks source link

Failed to execute postMessage on DOMWindow #65

Open mladentsvetkov opened 1 year ago

mladentsvetkov commented 1 year ago

Guys, why would one get this message when trying to integrate Zeplin in Storybook? Storybook is running on localhost without HTTPS.

Error message:

Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://app.zeplin.io') does not match the recipient window's origin ('http://localhost:6006').

Here is the trace:

The target origin provided ('https://app.zeplin.io') does not match the recipient window's origin ('http://localhost:6006').
postMessage @ vendors~main.manager.bundle.js:219108
(anonymous) @ vendors~main.manager.bundle.js:219923
(anonymous) @ vendors~main.manager.bundle.js:9282
AddonStore.loadAddons @ vendors~main.manager.bundle.js:9281
handleAPI @ vendors~main.manager.bundle.js:42949
init @ vendors~main.manager.bundle.js:10243
(anonymous) @ vendors~main.manager.bundle.js:13226
ManagerProvider._this.initModules @ vendors~main.manager.bundle.js:13222
invokePassiveEffectCreate @ vendors~main.manager.bundle.js:205376
callCallback @ vendors~main.manager.bundle.js:185839
invokeGuardedCallbackDev @ vendors~main.manager.bundle.js:185888
invokeGuardedCallback @ vendors~main.manager.bundle.js:185950
flushPassiveEffectsImpl @ vendors~main.manager.bundle.js:205463
unstable_runWithPriority @ vendors~main.manager.bundle.js:217639
runWithPriority$1 @ vendors~main.manager.bundle.js:193170
flushPassiveEffects @ vendors~main.manager.bundle.js:205336
(anonymous) @ vendors~main.manager.bundle.js:205213
workLoop @ vendors~main.manager.bundle.js:217588
flushWork @ vendors~main.manager.bundle.js:217561
performWorkUntilDeadline @ vendors~main.manager.bundle.js:217328
mladentsvetkov commented 1 year ago

Apparently this is not an issue, as the official example has the same error. Should we just ignore this error? Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://app.zeplin.io') does not match the recipient window's origin ('https://storybook-zeplin.netlify.app').

yuqu commented 1 year ago

You can safely ignore the error, it was addressed here.

Let's keep the issue open so that others may find the answer until we find a way to remove the error altogether.