Python may soon rival JavaScript for web applications

There is a new project which should allow the Python programming language to run in web browsers with the help of WebAssembly.

the CPython on WASM The project, which will build the default and most popular implementation of the Python language written in C, is being developed by Berkeley-based software developer Ethan Smith.

According to The register, the project was created with the help of lead Python developer Christian Heimes and could make Python a viable alternative to JavaScriptat least for some web applications.

Python on the Web

“The new project Christian Heimes and I are working on aims to make the web a supported platform for CPython, just like Windows or macOS,” Smith told The Register.

WebAssembly has taken the world by storm with its promise to take web-native application performance to a level not possible with JavaScript.

However, The register notes that at this point, the project’s goal of bringing Python to the browser via WebAssembly’s Emscripten compiler, is more about enabling use case rather than performance.

The project would follow another project, called Pyodide, which also allows Python code to run in the browser.

“I hope this will enable a broader ecosystem of web-targeted Python developers and enable easier integration with existing Python tools and processes, many of which Pyodide had to reinvent itself as micropip to replace the standard installer of the pip package,” Smith explained.

Smith hopes his project can make it easier to develop cross-platform web applications, but he’s quick to add that CPython on WASM is still in the early stages of development.