Hacker News new | ask | show | jobs
by brudgers 4765 days ago
The argument for compiling the Python with the pre-processor seems roughly analogous to traditional arguments for compiling rather than interpreting languages - i.e. how many times the conversion from source code to machine instructions must be done.

One isn't necessarily better than the other - sometimes human generated python source code in the browser may be more useful than machine generated javascript.

If nothing else, it allows us to explore a new way of constructing web apps and determine whether it is better.

1 comments

I'm not sure what the commenter meant, and perhaps a silly comment to make, but doesn't python's strong indentation make it harder to simply include on a webpage? proxies, ad filters, and other optimizers might break the lines in unexpected places.

I guess it can be solved by gziping the file, or base64 encoding it. But this is also an argument (albeit trivial or weak) for compiling it on the server rather than the client.