Over a million developers have joined DZone.

See the Tree Move Smoothly: Dynamic Graphs Using Web Workers and jQuery

DZone's Guide to

See the Tree Move Smoothly: Dynamic Graphs Using Web Workers and jQuery

· Web Dev Zone
Free Resource

Start coding today to experience the powerful engine that drives data application’s development, brought to you in partnership with Qlik.

The purpose of the emerging Web Workers standard is to help JavaScript programs run smoothly and predictably in the client's browser -- in other words, to open multiple JavaScript threads.

Which JavaScript, of course, like a beginning pianist learning only the right-hand part, can't do. From a purely computational perspective, this radical, built-in serialism is probably JavaScript's biggest problem -- or at least one of the obstacles to treating it as a full-fledged 'serious' language.

Web Workers fix that, in effect, but this post is about a library designed to combine one kind of multithread-ish-ness with another: arbor.js, a graph visualization library using Web Workers and jQuery.

One of the neat things about graph visualization, as opposed to (say) text-streams (or tables), is that a visible graph lets the user's eyes scan over multiple things at once, in a path the user chooses (though with some paths suggested by connecting lines) -- thus giving the user's massively parallel brain access to all kinds of information at once. 

And arbor.js does this extremely well, taking full advantage of cutting-edge web technology to produce extremely smooth visuals, with an extremely straightforward API. (That API reference page is coded pretty slickly too.)

Here's how one sample project looks:

Actually I'm a sucker for any graph (or tree), so this kind of thing especially lights up my brain.

But graphs are great for visualizing lots of different kinds of data, and Web Workers removes a major technical weakness of JavaScript -- so why not give arbor.js a try?


Create data driven applications in Qlik’s free and easy to use coding environment, brought to you in partnership with Qlik.


Opinions expressed by DZone contributors are their own.


Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.


{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}