Hacker News new | past | comments | ask | show | jobs | submit login
Zaphod - JavaScript written in JavaScript (mozillalabs.com)
57 points by j_baker on Jan 20, 2011 | hide | past | favorite | 10 comments



In case you were already familiar with Narcissus, this appears to just be Narcissus packaged in a Firefox addon, not a new JavaScript implementation written in JavaScript as the title implies.


You're correct. To me, JavaScript in JavaScript that can run in the browser was the most important part (although I should have added "in the browser"). If I had called it "Zaphod - run Narcissus in firefox", it probably wouldn't have gotten anyone's attention.


Give me an implementation of Harmony as described in http://brendaneich.com/2011/01/harmony-of-my-dreams/ in Narcissus, and I would certainly play around with this extension.


This is one of the main goals of Narcissus and Zaphod, actually, since it's much easier to hack Narcissus than SpiderMonkey. We're working on integrating Harmony proposals into Narcissus.


Sorry, can someone please give an overview of what this is and how it works (I did not find any detailed examples on the site).

My understanding is that its an alternative javascript engine that can be modified (using javascript itself I assume) and those modifications packaged and shared.

Is that right? I was looking for an example of how you modify the engine and what can be modified. Any ideas?



That directory is out of date. (I'm not sure why it hasn't been removed yet.) The new project page is here: https://github.com/mozilla/narcissus

We moved it to GitHub to make it easier for people to submit pull requests and the like.


Arh! I see.

So, when if I install this extension, I can hack those files (in the extension's directory I assume) reload the browser and the javascript engine will do whatever I have changed?


Try listening to Brendan Eich about what Mozilla is using Zaphod for, might give you some insight.

Using Zaphod to make Harmony available today: http://www.aminutewithbrendan.com/pages/20110110

General overview of Narcissus and Zaphod: http://www.aminutewithbrendan.com/pages/20101011


for those curious, this could provide similar benefits to javascript (or other dynamic) language experimentation that pypy does in python:

http://codespeak.net/pypy/dist/pypy/doc




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: