Skip to main content

JavaScript to Python Translator & JavaScript interpreter written in 100% pure Python.

Project description

Translates JavaScript to Python code. Js2Py is able to translate and execute virtually any JavaScript code.

Js2Py is written in pure python and does not have any dependencies. Basically an implementation of JavaScript core in pure python.

import js2py

f = js2py.eval_js( “function $(name) {return name.length}” )

f(“Hello world”)

# returns 11

Now also supports ECMA 6 through js2py.eval_js6(js6_code)!

More examples at: https://github.com/PiotrDabkowski/Js2Py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

js2py2-0.75.tar.gz (568.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

Js2Py2-0.75-py3-none-any.whl (609.1 kB view details)

Uploaded Python 3

File details

Details for the file js2py2-0.75.tar.gz.

File metadata

  • Download URL: js2py2-0.75.tar.gz
  • Upload date:
  • Size: 568.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.0

File hashes

Hashes for js2py2-0.75.tar.gz
Algorithm Hash digest
SHA256 e2291fc70b4835701287b6b98573f4ac9d40b72e5808ae611bfbb0d1ad46241c
MD5 28609d2ac52201af7038b2f750509035
BLAKE2b-256 1fdce3ce82cbe32758ec9b559320c5e45443e44651c2313a43126bef3b9a028b

See more details on using hashes here.

File details

Details for the file Js2Py2-0.75-py3-none-any.whl.

File metadata

  • Download URL: Js2Py2-0.75-py3-none-any.whl
  • Upload date:
  • Size: 609.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.0

File hashes

Hashes for Js2Py2-0.75-py3-none-any.whl
Algorithm Hash digest
SHA256 25a144805c9efd3c2686db1acf256f96051ff656f18e1ae59c8f80862f689140
MD5 3238dc4e2c6054674a1eac3f19433c3a
BLAKE2b-256 e912644faa41e05ea677671124bec78da7bd60fff19cb64b4557bad029e17c4b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page