Here is the release video for new version of plotly.kt:
• Full coverage of basic Plotly API (fully type-safe with autocomplete etc.)
• Full-stack support for rendering from the servers side (with dynamic real-time updates!).
• Client side rendering with Kotlin-JS and coroutines.
• Experimental support for Kotlin-jupyter.
• Experimental scripting support.
• JavaFX demo.
08/24/2020, 2:20 PM
If plotly is a JS library, how it works that you enter code in the browser, see results in the browser, but the engine is using ktor on JVM?
08/24/2020, 2:23 PM
The basic behavior is to enter the code in th JVM. The core then shapes and accumulates the updtate and then sends it to the client via web-sockets push mechanism. If you add Jupyter to the mix, it works backwards, it has its own server that recieves the code from the frontend and then evaluates it. In case of active jupyter-server we actually have two separate servers: one for the jupyter itself and one for direct widget updates.
Actually the core of the library is not plotly-specific, it could be used to aggregate and dynamic updates.
08/24/2020, 2:29 PM
the output (send via web-sockets) is svg? png?
08/24/2020, 2:30 PM
No, it is a plain json that is interpreted on the client side.
08/24/2020, 2:31 PM
by the plotly js lib?
08/24/2020, 2:32 PM
yes. The idea is the sam as in a basic full-stack application, but the roles are reversed. You generate json on the backend and send the request to the front-end. This way, the browser is actually a server and the JVM is a client