Live data from Hacker News

Introducing node-firefox

hacks.mozilla.org

11–20 of 53 posts

Re: Introducing node-firefox

#11
post #9

v8 powering Firefox, who would've known...

... IIRC , there is a node-spidermonkey version,but Mozilla doesn't seem to be interested in working seriously on that project. Which is crazy because one would expect Mozilla to do exactly that.

I'd rather see the node-servo version ;)

As far as I understand, Servo will come with a WebKit embedding API, so the possibilities are pretty much endless.

Re: Introducing node-firefox

#12
post #9

v8 powering Firefox, who would've known...

... IIRC , there is a node-spidermonkey version,but Mozilla doesn't seem to be interested in working seriously on that project. Which is crazy because one would expect Mozilla to do exactly that.

Sadly dead - https://github.com/zpao/spidernode

Re: Introducing node-firefox

#13
post #9

v8 powering Firefox, who would've known...

... IIRC , there is a node-spidermonkey version,but Mozilla doesn't seem to be interested in working seriously on that project. Which is crazy because one would expect Mozilla to do exactly that.

Last I heard, the node guys were quite adverse at maintaining both node-v8 and node-spidermonkey. I don't blame them ;)

And that doesn't help that the people who started node-spidermonkey left Mozilla and afaik can't contribute to open source projects that are not explicitly vetted by their current employer.

Re: Introducing node-firefox

#14
post #6

Maybe this isn't the best place to ask, but how is the performance of Firefox OS? Its mostly marketed for low-cost devices, how well do apps based on web tech actually run on these relatively slow SoCs? Firefox for android performs admirably for webpages on my nexus 5, but I have yet to find an interactive web app, whether in Firefox or packaged as a Cordova app (and therefore WebKit+v8), that doesn't feel very slugg…

The performance is very acceptable for what I saw (basic usage of all of the provided apps).

I am no expert, but the FirefoxOS stack is really lean and simple compared to the Android stack. Some would say that Android is an huge undocumented bloat with all the layers added during its lifetime (just check the AOSP build system to understand this opinion).

As I see it, FirefoxOS, by being ten years younger and less used, is doing million things less than Android (from the system point of view), and that's how things can get reasonably fast and responsive (that, and the blazing fast SpiderMonkey vm).

Re: Introducing node-firefox

#15
post #11
post #9

Earlier quoted context omitted.

... IIRC , there is a node-spidermonkey version,but Mozilla doesn't seem to be interested in working seriously on that project. Which is crazy because one would expect Mozilla to do exactly that.

I'd rather see the node-servo version ;) As far as I understand, Servo will come with a WebKit embedding API, so the possibilities are pretty much endless.

Servo uses spidermonkey as JS engine, so I don't think it brings anything in a "run js headless" context.

Re: Introducing node-firefox

#16
I am kind of disappointed in the naming of this. There's another project named Node-WebKit: https://github.com/nwjs/nw.js/tree/master It allows you to build a native app using node and webkit.

Reading the name of this project got my hopes up, thinking I was going to have the option of using Firefox instead of Webkit as my rendering engine. Oh well.

Re: Introducing node-firefox

#17

I am kind of disappointed in the naming of this. There's another project named Node-WebKit: https://github.com/nwjs/nw.js/tree/master It allows you to build a native app using node and webkit. Reading the name of this project got my hopes up, thinking I was going to have the option of using Firefox instead of Webkit as my rendering engine. Oh well.

That would be node-gecko (if it existed), wouldn't it? But yes, it's a bit misleading, by node-firefox I was expecting the full blown browser written in javascript myself.

Re: Introducing node-firefox

#18
post #17

I am kind of disappointed in the naming of this. There's another project named Node-WebKit: https://github.com/nwjs/nw.js/tree/master It allows you to build a native app using node and webkit. Reading the name of this project got my hopes up, thinking I was going to have the option of using Firefox instead of Webkit as my rendering engine. Oh well.

That would be node-gecko (if it existed), wouldn't it? But yes, it's a bit misleading, by node-firefox I was expecting the full blown browser written in javascript myself.

Or some thing like node-js but using SpiderMonkey instead of V8. Name really does not fit and blows up expectations. node-firefox-simulator would be more apt.

Re: Introducing node-firefox

#19
post #6

Maybe this isn't the best place to ask, but how is the performance of Firefox OS? Its mostly marketed for low-cost devices, how well do apps based on web tech actually run on these relatively slow SoCs? Firefox for android performs admirably for webpages on my nexus 5, but I have yet to find an interactive web app, whether in Firefox or packaged as a Cordova app (and therefore WebKit+v8), that doesn't feel very slugg…

I work on Firefox OS so probably worth taking bias into account.

On low end devices fxos runs reasonably well but with noticeable lag, we have put in huge amounts of effort on the low end to make that possible. On high end devices the 'native' fxos application are incredibly snappy and there has been very little done to improve performance on high end devices.

Most of the stuff we have done is common sense, some you will see a lot of people doing, some almost no people do.

1. Shorten the path to rendering first screen, dont block on reading some data, load all scripts async etc.

2. Never animate top / left, use CSS transitions for everything.

3. We use 'will-change' to ensure that the graphics are properly layered for when they do animate (https://developer.mozilla.org/en-US/docs/Web/CSS/will-change)

4. Offline assets, in fxos we use packaged apps for various reasons, however one of the benefits is that reading from the filesystem is faster than reading over the network.

If I had one performance tip for web developers, look into how far you can use appcache to store resources offline (or if your feeling fancy, service workers). Offline capable web apps have a night and day difference.

Re: Introducing node-firefox

#20
post #17

Earlier quoted context omitted.

That would be node-gecko (if it existed), wouldn't it? But yes, it's a bit misleading, by node-firefox I was expecting the full blown browser written in javascript myself.

Or some thing like node-js but using SpiderMonkey instead of V8. Name really does not fit and blows up expectations. node-firefox-simulator would be more apt.

https://github.com/zpao/spidernode
Post reply on HN