bokeh / bokeh-fastapi

BSD 3-Clause "New" or "Revised" License
9 stars 2 forks source link

Improve integration with Panel #6

Closed philippjfr closed 1 month ago

philippjfr commented 6 months ago

This PR does two things:

  1. Improve the _eval_panel wrapper to ensure that functions are given the correct pn.state.curdoc context and that we run Panel's onload handlers
  2. Add integration with Panel's immediate dispatch mechanism, ensuring that Panel does not error when it dispatches events across the websocket.

In the long run we will have to work out whether the _eval_panel code really should live in this repo or whether we should simply merge bokeh-fastapi support upstream. The same is true with the dispatch_fastapi hook.

Depends on https://github.com/holoviz/panel/pull/6820

philippjfr commented 1 month ago

Integration will now live in panel.io.fastapi.