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

Js2Py-0.72.tar.gz (2.5 MB view details)

Uploaded Source

Built Distribution

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

Js2Py-0.72-py3-none-any.whl (1.0 MB view details)

Uploaded Python 3

File details

Details for the file Js2Py-0.72.tar.gz.

File metadata

  • Download URL: Js2Py-0.72.tar.gz
  • Upload date:
  • Size: 2.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/33.0 requests/2.28.1 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.8.2 keyring/23.5.0 rfc3986/1.5.0 colorama/0.4.4 CPython/3.9.15

File hashes

Hashes for Js2Py-0.72.tar.gz
Algorithm Hash digest
SHA256 13d829abcd6422fe3d3b5594cae9cbfa4cb8cc5add9b8c284c39fdc3a0b53936
MD5 cee56bd0e8e14bbcce1a88d7f271b44b
BLAKE2b-256 2c5e7d6dff6c36f95a5c320cd0e1354e375234532bd2cddd687d22d813176e20

See more details on using hashes here.

File details

Details for the file Js2Py-0.72-py3-none-any.whl.

File metadata

  • Download URL: Js2Py-0.72-py3-none-any.whl
  • Upload date:
  • Size: 1.0 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/33.0 requests/2.28.1 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.8.2 keyring/23.5.0 rfc3986/1.5.0 colorama/0.4.4 CPython/3.9.15

File hashes

Hashes for Js2Py-0.72-py3-none-any.whl
Algorithm Hash digest
SHA256 f7bda9d37053a2fef52692489ac09adeb945c8cd802a4a8f289081ce4d61847f
MD5 cc801bec28e51a62bfd0d6cada264e8a
BLAKE2b-256 c0dd094d69220000f36c8499eef806c37f4f492c7f7ba121304bf27601387b9d

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