Hacker News new | ask | show | jobs
by drivingmenuts 4764 days ago
I dream of a day where I can choose what language to script a page in, using a native implementation, rather than being forced to use javascript.

Javascript is great, but I'd rather work in Python and have it be actual Python, not an interpreter written in an interpreted language.

1 comments

Apologies for going off-topic, but why ISN'T that an option now? Was that not the point of "type" in <script> in the first place? (That's a genuine question; I don't know the history of the <script> tag, or its "type" attribute.

How is V8 wired into Chrome, or Rhino(?) into Firefox, for example? Is there a great technical barrier to making it possible for the user to install an interpreter of their choice? As I understand the course of the browser's history, it already seems to be moving to an OS-style program (or, in Chrome's case, it has BECOME an OS), so it seems like user-loaded language runtimes OUGHT to be on SOMEONE'S mind. And I'd be surprised if it hasn't already occurred to someone before, I just don't know the history.

Has anyone attempted to write a browser that allowed for such a thing? Or has JS just been the accepted scripting language, and no one has yet tried to push past?

IIRC, Microsoft tried to get vbscript to catch on, but it didn't. I think it was a case of one language doing the trick adequately, and adding more would just multiply the headaches for development and building cross-browser compatible code. What happens when Firefox supports Python 3, Microsoft supports Python 2 (but not actual python 2, their own proprietary version) and Opera just happens to only ever run javascript?