Weblogs: Javascript

@Media Ajax - Day one

Monday, September 15, 2008

Making another appearance in London is @Media Ajax, bringing together diverse speakers and topics in the field of JavaScript and rich internet applications.

Brendan Eich and faster-than-light JavaScript

Brendan Eich talked centred around the features that may arrive in Firefox 3.1. Covering javascript runtime performance, particularly of the TraceMonkey JavaScript engine and how it compares to other JavaScript engines. On the topic of Chrome's V8 engineer, Eich conceded that it was indeed fast, but slower on strings and regex, while Internet Explorer 8 beta 2 was still very far behind on the performance curve versus other modern browsers.

Looking ahead Eich ventured that we will soon see near-native speed JavaScript in browsers, both on the desktop and mobile devices. Internet Explorer is still a problem, and developers need to make their voices heard in order to push Microsoft into focusing on catching up in performance.

One potential option, if Microsoft does nothing, is to use Flash as a basis of improving the performance of JavaScript in that browser.

Eich showed off the performance increases in TraceMonkey, including an intensive image fade in / fade out effect that went from 1 frame a second on the current JavaScript engine to up to 10 frames a second with TraceMonkey.

With HTML5's web workers - a form of multi-threading or parallel processing, the FIrefox 3.1 nightly builds showed some performance improvements on computational heavy tasks. Eich conceded that his dual-core Macbook Pro won't show a big improvement when using two worker threads, but quad cores will show a significant improvement.

Eich then took us on a tour of new CSS features that may surface in Firefox 3.1. From CSS Transforms (-moz-transform:rotate(90deg)) rotating elements, the :nth-child(2) pseudo-selector for zebra-striping tables, text-shadow effects I thought had been left in the last century.

Technically interesting demos of using SVG shapes as CSS clip-region styles, as well as edge-detection based on SVG shapes. These are the sort of rendering tricks that previously required plugins.

Eich's point was that a web developer shouldn't need to learn Flash to be able to do these things. He's aiming for a 'no plugins required' state.

HTML 5 wise, Eich is working towards free codecs for the video and audio elements. Opera already has ogg vorbis support, Firefox will have this soon. The BBC DREC codec is high on that list.

I found the presentation unfocused with no real underlying direction or theme. Interesting bits and pieces, just having no cohesion.

Richard Rutter on Wireframing Ajax interactions

An interesting talk about wireframing from an interaction design point of view. He starts off talking about the steps in interaction design, and impresses that it is an iterative process. He takes us through wire frames of largely static sites, describing the approaches and design themes, like the concept of patterns and progressive disclosure, and explains why empathy and experience offer better insights into how to create usable experiences.

The Ajax wireframing is limited to HTML mockups with some jQuery bits to prototype effects mostly using show/hide effects. This is using a customised plugin for jQuery (PolyPage) which using classes to toggle effects, notes and views.

Questioned on how progressive enhancement is handled, Richard admitted that it was handled later through conversation, and not really dealt with at the wire framing stage.

A fairly interesting presentation topped off by being based heavily on real world examples and practice.

Christian Heilman introducing Scripting Enabled

Christian makes a convincing argument that what's missing from accessibility circles is acceleration, or working together in the same direction. We'd be a big force if we can work together in the same direction around accessibility concerns.

One source of inspiration to Christian is Artur Ortega, an exceptional engineer working for Yahoo. He wrangles code with the best of them, with his screen readers and refreshable braille display. He initially wrote a greasemonkey script to insert lang attributes into Yahoo search results, allowing different languages being read out in their correct accents. This hack was one that got implementing, making Yahoo Search the first search engine to be international friendly. This inspired Christian to turn his hacking instincts towards accessibility.

Christian backs up his argument with a great collection of examples of where the 'evil' JavaScript and Flash has been used to improve accessibility of content to various disabled groups, including the phenomenal and inspiring example of live.yahoo.com revolutionalising communication between deaf people online.

Other examples include Christian's own well-received easy YouTube player, which included some excellent feedback from the cognitive disability community.

Christian's Scripting Enabled is an accessibility hackday. It starts this Friday (19th September 2008) with talks about the problems disabled people are facing online, this leads into the hackday on Saturday where hackers are invited to flex their skills into fixing these problems.

A typically enjoyable, inspiring and informative presentation from the ginger one.

Michael Mahemoff on Open Social

Mahemoff talks about the Open Social container, about how gadgets fit together. He takes us through a single XML gadget 'specification' showing how this relates to what is displayed.

Unfortunately, Gadgets seem to be nothing more than HTML and a chunk of JavaScript - reminding me of RSS plus a little JavaScript to render the document. I found it hard to accept that iframes were the best solution for multiple gadgets, especially considering the accessibility implications (one gadget is effectively one entire page by itself).

Dion Almer on Gears and HTML 5

Another interesting talk, Dion takes us through all the components (or cogs) of Gears along with small snippets of code to give an excellent overview of what is possible. From offline applications, through to geo-location and audio capabilities.

I was particularly fascinated by the local database and what seems like a mini web server acting as a caching layer.

Dion highlights that Google wants to improve the web platform for developers, and when it spots potential for reusing code, that gets built as a gear and added to the collection on offer. In Google's eyes, they see Gears as an interim solution until browsers offer their own native support, and over time Gears will continue to push on the cutting edge of innovation.

Dion compares the Gears components with the HTML 5 list of new features, and there's a very strong match. Probably not coincidence considering Gears is a Google effort, and HTML5 chief editor - Ian Hickson - is a Google employee.

A good overview of Gears. And considering Chrome has Gears built in, I'm keen to have a deeper look and play with the Gears components.

Jake Archibald on Reusable JavaScript

Jake is a Senior Developer on Glow, a JavaScript library created by the BBC for its websites. Jake raises a number of interesting questions about creating reusable javascript, and discusses how Glow tackles each one to result in a library that looks to fill the BBC's needs fairly well.

The core of Jake's argument is the three layered approach to building a library. This is good documentation, well-specified API, and well thought out code. He takes us through a number of issues and turning points in bringing together all the features of Glow.

One particularly instructive example was the modal dialogue box. Jake shows that it can be up and running with default settings with a single line of code, and then proceeds to demonstrate just how flexible by using a configuration option to override the default values, including even the actual HTML template used to construct the widget.

Along with a number of running gags (particularly on BBC's commitment to impartiality, and the failings of Internet Explorer), this turned out to be a surprisingly good presentation, with great advice.

Asked why the BBC didn't just build ontop of an existing JavaScript library the core reason was the range of browser that the BBC need to support is wider than open source libraries are willing to handle. I'm disappointed that Jake's bugfixes to YUI to add Safari 1.3 were basically dismissed by the YUI guys. True, Safari 1.3 isn't a Grade-A browser within Yahoo, but we've missed a great opportunity to work closely with the BBC. Also, like our graded browser support, the BBC's choice of supported browsers is based on their visitor stats and economic realities - there's a good pragmatic reason the BBC feel they need to continue supporting Safari 1.3.

An entertaining, instructive and insightful presentation from Jake Archibald. Lots of points to consider, and integrate into our development processes.


[ Weblog | Categories and feeds | 2011 | 2010 | 2009 | 2008 | 2007 | 2006 | 2005 | 2004 | 2003 | 2002 ]