Dear ImGui Bundle on the Web via Pyodide #361
pthom
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Dear ImGui, in the browser. In Python. With all the immediacy you’d expect; and none of the JS.
Thanks to Pyodide support (added in v1.92.0), you can now build and run Dear ImGui apps on Web, using Python.
Below is a minimal example that draws a heart shape and allows you to adjust the heart pulse rate using a slider. Its code is surprisingly short: it fits in a single 50 lines file, almost entirely in Python (with a bit of HTML and JavaScript). Since pyodide's distribution is available via a CDN, you can reproduce this on your side : just copy-paste code below into a html file
Note: Dear ImGui Bundle brings full support for docking, ImPlot, Markdown, node editors, image tools, and more, in both desktop and web builds.
Code for this minimal demo
This runs:
* in your browser
* in pure Python (via Pyodide)
* with real ImGui + ImPlot rendering (no HTML/CSS involved)
An online playground will enable you to run ImGui applications in the browser without any setup.
ImGui Bundle is now available in the standard Pyodide distribution!
Beta Was this translation helpful? Give feedback.
All reactions