The native language of the Web Browser is JavaScript. Every modern web browser comes with a JavaScript engine responsible responsible for parsing and executing JavaScript code. As such, most of the web standards and behaviors related to programming behavior on the page deal directly in JavaScript. What's more, almost every useful frontend or Node framework is written in JavaScript.

Pyodide and PyScript allow the user to take advantage of these existing resources and functionalities through the use of a "translation layer." This layer is responsible for translating JavaScript objects to Python objects (and vice versa), and allowing objects from one langauge to be used as objects of the other.

Simple immutable objects, like string and integers, are converted directly to their corresponding types. More complex or mutable objects are passed by reference as a Proxy of the object from the other language. For more details about how and when objects are converted or Proxied see the Pyodide Documentation

The remainder of this category explores how to make use of this functionality.