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 nearly identical to what you'd write for a native ImGui app — just translated to Python and wrapped in a Pyodide shell.
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.
You can download the Pyodide distribution with ImGui Bundle pre-installed from the following link: Download Pyodide with ImGui Bundle
ImGui Bundle is in the process of being added to the official Pyodide recipes, so you will be able to use it without downloading anything in the future. See relevant PR
Beta Was this translation helpful? Give feedback.
All reactions