Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom WYSIWYG editor not rendering #167

Closed
gmarraro-ellevest opened this issue Jun 14, 2018 · 1 comment
Closed

Custom WYSIWYG editor not rendering #167

gmarraro-ellevest opened this issue Jun 14, 2018 · 1 comment

Comments

@gmarraro-ellevest
Copy link

I've created a custom WYSIWYG editor with Froala-React and everything is working fine when I run it through localhost. However, when I set it up as an extension in Contentful, the extension appears to be rendering (as seen in the dev tools), but nothing is actually showing up on the screen. Two errors I'm getting are:

Uncaught DOMException: Failed to set the 'cookie' property on 'Document': The document is sandboxed and lacks the 'allow-same-origin' flag. at http://localhost:8080/bundle.js:11237:138801 at new Ee.FE.MODULES.data (http://localhost:8080/bundle.js:11237:138898) at s.load (http://localhost:8080/bundle.js:11237:4692) at s.<anonymous> (http://localhost:8080/bundle.js:11237:2021) at HTMLDivElement.proxy (http://localhost:8080/bundle.js:10635:14) at HTMLDivElement.dispatch (http://localhost:8080/bundle.js:5755:92) at HTMLDivElement.elemData.handle (http://localhost:8080/bundle.js:5560:104) at Object.trigger (http://localhost:8080/bundle.js:8714:13) at HTMLDivElement.<anonymous> (http://localhost:8080/bundle.js:8786:18) at Function.each (http://localhost:8080/bundle.js:1155:19)

bundle.js:15292 TypeError: Cannot read property 'off' of undefined at t.value (bundle.js:11476) at t.value (bundle.js:11451) at Wg (bundle.js:15306) at Xg (bundle.js:15364) at Xh (bundle.js:15648) at Rh (bundle.js:15588) at Uh (bundle.js:15572) at Sh (bundle.js:15567) at wh (bundle.js:15548) at kg (bundle.js:15504)

...but I'm not sure if that's my main problem.

This is all that's rendering now:
screen shot 2018-06-14 at 3 51 17 pm

Any ideas?

@floelhoeffel
Copy link
Contributor

floelhoeffel commented Jun 15, 2018

It seems like your extension tries to set a local cookie which is not allowed by the policy of the iframe. Its actually in your error message:

Uncaught DOMException: Failed to set the 'cookie' property on 'Document': The document is sandboxed and lacks the 'allow-same-origin' flag.

So for now you might try to deactivate that in your editor. We are currently trying to apply a more flexible policy so setting a cookie might become possible. I keep you posted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants