Home > python > pythonium: a Python to JavaScript translator

pythonium: a Python to JavaScript translator

Pythonium is a Python 3 to Javascript translator written in Python that produce fast portable JavaScript code.

Example:

$ echo "for i in range(10): print(i)" >> loop.py
$ pythonium -V loop.py
var iterator_i = range(10);
for (var i_iterator_index=0; i_iterator_index < iterator_i.length; i_iterator_index++) {
    var i = iterator_i[i_iterator_index];
    console.log(i);
}

I haven’t tried it yet, so this post is a reminder for me to check it out.

Advertisements
Categories: python Tags:
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: