I’m looking at rendering jupyter-widgets within a web context and although I think I can successfully render the view of a widget, I am having trouble getting hold of or figuring out how to access the widget state information.
Specifically I am looking for widget state that i can drop into a
<script type="application/vnd.jupyter.widget-state+json"></script> tag and then have this available on page for the widget view to render.
I am looking for how to retrieve that programatically but not had any luck so far, even though this appears to be connected to the “Save Widget State” setting in lab and the “Embed Widgets” menu item in the classic notebook.
If anyone has any pointers of where to look to better understand where widget state is stored and how to retrieve it, or if i’m just on the wrong track! I’d appreciate the info.
- can this be accessed via the jupyterlab-manager? toJSON?
- is there somewhere on the global jupyterlab object that exposes this manager? or other appropriate object/calls?