Warning: this post is for techs only (or those aspiring to tech-dom)!
I was keen to get a “vision of JS’s future” directly from the people who call the shots. And it´s always helpful to step away from everyday work and broaden one’s horizons in understanding the current state of JS and Web technologies.
First off the organization of the event was at a high level. The time for talks, coffee breaks and lunches was well-balanced. Great opportunities for informal communication between the participants, organizators and speakers were provided including evening meetups in hip bars and, during the day, nice long lunches (yes, it’s Spain and they take their siestas seriously no matter what the rest of the world thinks) plus a great wrap-up party in one of the best and biggest casual night clubs in Barcelona (Razzmatazz).
Overall there were fifteen talks over two conference days (Videos are located here). Some were dedicated to the language itself: its history and possible future evolution, strengths, weaknesses and ways of using the newest features of the just-emerging ES6 standard.
It was one of those talks (by Reginald Braithwaite) that was, for me, amongst the most interesting and inspiring. Reginald talked about functional programming and object oriented programming, and emphasized JS’s inherent minimalism. The language doesn’t contain ready functional constructs or concepts and it doesn’t force us to use a functional approach, but it has enough tools for developers to code in a functional style if they prefer (functions as first-class entities). The same with OOP – JS doesn’t support all the concepts of classical OOP, but Reginald showed how we can emulate them ourselves using the available means (objects and prototypal inheritance).
Also Reginald explained the idea of creating modular programs based on functions, thereby making code more reliable and reusable. According to this approach a program consists of two groups of functions: ones that implement business logic, main building blocks of an application; and service functions (composers, transformers) – general-purpose routines applied to the business logic blocks or to another service functions (they are going to be the same for different applications). For this approach to be successfully implemented the business logic functions have to be properly isolated and encapsulated.
Obviously, the new language standard ES6 demanded its due (specification drafts can be found here). Patrick Dubroy toured us through its new features with an emphasis on the question – how to use all these goodies just now when most browsers don’t fully support them? While such features as new methods of API can be easily polyfilled, the new language syntax and constructions require more cunning approaches. Enter the compiler Traceur. It takes code containing new ES6 features and transforms it to ES5 (or even ES3) compatible code. Patrick also demonstrated, through examples, exactly how transformations from ES6 to ES5 are done, from elementary ones like the => (lambda) operator to more complex stuff like generators.
The other talks were devoted to the newest APIs and frameworks. One such talk was about the Web Audio API (http://www.w3.org/TR/webaudio). Jaume Sanchez explained its main idea and constituent concepts. Web Audio enables the mixing, processing, and filtering tasks that are found in modern desktop audio production applications. The model of Audio Nodes – audio processing nodes connected into the processing net (or graph) – is the key concept of the Web Audio API.
Yet another talk covered Web components and Shadow HTML (http://www.w3.org/wiki/WebComponents). Martin Naumann described the use of Web components to build modular Web applications. The coolest thing about Web components is that developers no longer need specialized frameworks and tools (like angular directives) or components built with other languages and technologies (for instance, Java applets) to create reusable, well-isolated, reliable widgets for Web applications; standardized technologies such as Shadow DOM and custom HTML elements can be used instead.
Next, the idea of a virtual DOM was presented by Pete Hunt. The virtual DOM was worked out as an alternative approach of organizing data binding in situations where current approaches were not ideal from a performance perspective. The classical implementation of data binding is based on the key/value collections observation (Ember, Knockout). The main competitor of this approach is dirty checking (Angular). The virtual DOM bumps performance while working effectively with the data binding update history: the current state of bound UI elements is determined as a collection of changesets applied to their initial state.
The awesome talks were hugely important but not the only valuable part of the event. Informal discussions with people from all over the world who work with JS were great as well. Among the attendees were JS developers, managers, business owners, and technical consultants. It was very helpful to exchange the experience of applying JS in different business solutions, and these exchanges revealed the growing potential of the language and the technologies related to it.
The future of JS is filled with promise… and it´s coming up fast!