Savannah Ostrowski @savannah.dev · Jan 21

Hacking on an embeddable Python REPL, powered by Wasm/Pyodide. My goal is to make it super simple to get Python running on a website...so that there's no package installation required, just specify the script tag and div and you're done (supports theming and package installs via attribute as well)!

60 likes 4 replies

?

Replies

Savannah Ostrowski · Jan 21

So you can just do <script src="https://cdn.jsdelivr.net/npm/pyrepl-web/dist/pyrepl.js"></script> <div class="pyrepl"></div> (and then optionally strap on attributes like data-theme="catppuccin-mocha" or data-packages="pydantic, requests, whatever" and everything is taken care of for you!)

flofriday · Jan 21

This is awesome! Two questions: I see the bundle is quite big (~10MB), so do you think it would be possible to lazy-load it, such that it won't be downloaded until it's needed? Can we use this for a better REPL on python.org?

@pierre-augier.bsky.social · Jan 21

Differences and relation with pyscript.net?