Python to Javascript compiler
Python JavaScript
Failed to load latest commit information.
pyjs Exclude argnames when finding locals. Mar 13, 2011 Fixed Readme filename. Feb 17, 2011 Added support for more nodes. Feb 17, 2011

pyjs: Python to Javascript compiler

pyjs compiles Python code into Javascript.

>>> import pyjs

>>> print pyjs.compile("def square(x): return x*x")
function square(x) {
    return x*x;

Release Plan


  • Compiles all python code
  • Not supported: imports, classes, yield, list comprehensions, generator expression, nested scopes, keyword arguments, ellipses, exec


  • nested scopes
  • keyword arguments