-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Set a cookie from callback function #182
Comments
My immediate thought was that this could be done with a callback that inserts a <script> tag with some JavaScript that sets a cookie, but according to MDN, the html5 spec says that <script> tags inserted via innerHTML should not execute. So no go there. There are other ways to get arbitrary JS code to execute via innerHTML, which might work (the same MDN article provides an example of how), but at that point it's definitely a hack job. |
Thank you for response! Interesting and useful workaround. But despite the fact it's a hack job, setting |
I suspect this could be a custom Dash component. What's the use case that you have in mind? |
Update toolchain
* - alter editable / readonly behavior * bump version * remove phantom file * update docs * fix lint issues * update variable names * remove merge file!
* - alter editable / readonly behavior * bump version * remove phantom file * update docs * fix lint issues * update variable names * remove merge file!
It seems that setting a cookies from callback function is currently impossible. I think it would be great if this feature will appear in the future versions.
Thank you:)
The text was updated successfully, but these errors were encountered: