Node.js fork JXcore goes open source, aims for mobile developers

The JXcore variant of Node.js bristles with intriguing features and aims to move Node into the mobile world

fork road
Credit: Ian Paterson

With all the noise surrounding the Io.js variant of Node.js, it's easy to forget about another Node fork that's been quietly percolating: JXcore. Last year it added multithreading (sort of) and the ability to turn Node apps into stand-alone executables -- but at the cost of JXcore being a closed source project.

Earlier this week, JXcore's creators undid that restriction, declaring JXcore an open source project and placing it under an MIT-style license. In addition, future editions of JXcore will endeavor to include JavaScript engines -- plural -- to make Node useful in mobile contexts.

In the blog post, JXcore's developers describe how JXcore's design makes it possible to incorporate multiple JavaScript engines. JXcore already works with multiple JavaScript engines and currently uses both the V8 JavaScript engine and Mozilla's SpiderMonkey engine. One advantage to having SpiderMonkey under the hood: Node.js applications can benefit from using asm.js, a subset of JavaScript designed to compile at near-C/C++ speeds.

But mobile support is the big, long-term project. An earlier post noted that a lightweight version running on iOS is a goal for the newly open-sourced JXcore.

A similar project, Nodelike, aims to bring a "Node.js-compatible API" to iOS -- by making use of the existing JavaScript engine, rather than bundling a new one. But Ugur Kadakal, CEO of Nubisa, the company behind JXCore, doesn't believe this sort of approach will work in the long run.

"We had to modify a significant portion of the Node core to achieve multi-engine capability," Kadakal wrote in an email, "as Node, by design, is tightly integrated with V8 and its API. That's why there were several failed attempts, i.e. SpiderNode, in the past to develop a version of Node with SpiderMonkey. They all failed because of the significant amount of changes required."

To that end, work is under way to implement "a lighter JavaScript engine for IoTs," apparently powered by an LLVM front end. Such work echoes that done by Apple's FTLJIT project and Emscripten, but JXcore faces a tough battle because of the tight memory and processor requirements for any mobile endeavor.

A caveat for those already using a build of JXcore: Only the most recent beta build of JXcore is available with open source licensing. Prior builds remain closed source for now.

From CIO: 8 Free Online Courses to Grow Your Tech Skills
Notice to our Readers
We're now using social media to take your comments and feedback. Learn more about this here.