Comments (4)
Ok. Got it:
def f(event):
print('hi')
b = bm.Button()
w = BokehModel(b)
b.on_click(f)
w.render_bundle = w._model_to_traits(b)
b._update_event_callbacks()
w
from jupyter_bokeh.
Just noting that private APIs can change or be removed at any time so using those methods is purely at your own risk.
We could consider crafting a supported, public API for this, but I think we'd need to understand the use-case better. The intended usage of BokehModel
is to be a "last mile" bridge for certain jupyter integrations. I.e. the intent is to set up all your Bokeh models normally up front, then only use BokehModel
as the last step.
from jupyter_bokeh.
This makes the following layout impossible to implement:
Bokeh plot1
Ipywidget Slider
Bokeh plot2
(or rather a horizontal version of this widget sequence)
I realize that I could use the bokeh slider instead of the ipywidgets one. But not all ipywidget widgets have their counterparts in bokeh.
from jupyter_bokeh.
We need to let BokehModel
listen to the underlying model's changes and refresh its render_bundle
.
from jupyter_bokeh.
Related Issues (20)
- RadioButton fires duplicate events on click HOT 3
- Displaying same figure with show and BokehModel
- stretch width + ipywidgets
- 'Models must be owned by only a single document' issue HOT 2
- Does not work with the latest version of ipywidgets HOT 5
- Push_notebook function not working in JupyterLab HOT 2
- 'NoneType' object has no attribute 'lookup'
- Change request for BokehModel initialization: call to standalone_docs_json_and_render_items error HOT 9
- Issue installing jupyter_bokeh in VSCode HOT 6
- Update `trigger_json_event` for Bokeh 3 HOT 1
- Wheel fails to build in Windows when user name is too long HOT 1
- 'Document' object has no attribute 'apply_json_event' (jupyter_bokeh/widgets.py:135) HOT 4
- whould it be possible to have wheels again in the pypi download ? HOT 2
- Error while running notebooks in VS Code HOT 3
- Old version of jupyter-bokeh will be installed if jupyterlab>=4 is installed HOT 6
- Where is jupyter_bokeh 4.0.0? HOT 4
- Concerning browser warnings with JupyterLab 3.6.7 and jupyter_bokeh 3.0.7 HOT 3
- push_notebook doesn't update in VSCode .ipynb HOT 17
- Failed to register jupyter_bokeh HOT 4
- conda HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jupyter_bokeh.