3 ms·
https://brython.info/ https://brython.info/
by wiz21c 5y ago
https://brython.info/ https://brython.info/
- lacraig2 5y agoIt would be helpful if someone could clarify some differences between Brython and Pyodide.
- mkl 5y agoThat's totally different. Pyodide is CPython in WebAssembly, and can use existing Python libraries (including those written in or backed by C), like NumPy, Pandas, and MatPlotLib. Brython transpiles Python code to JavaScript, so can handle some pure-Python libraries only: https://stackoverflow.com/questions/57517734/how-to-import-numpy-or-the-other-library-using-brython https://stackoverflow.com/questions/57517734/how-to-import-n...
- BiteCode_dev 5y agoBrython => a JS Python implementation. It will not behave like cPython for somethings, does not have access to the whole stdlib nor the scientific stack. But it is quite small (700ko without their stdlib) and has native bindings to the DOM. Use it if you feel like writing your web page in python (I wouldn't, I love python but 700ko+ with no framework loaded yet is way too much). Pyodine => the cpython implementation, but compiled to wasm. It's very heavy (10Mo), but it brings the real, whole cpython implementation in the browser so it will behave the same and have the entire stdlib. It also comes with optional NumPy, Matplotlib, pandas, SciPy, and scikit-learn. Use it if you want people to write python in the browser, but don't want to expose your server to their code.