Important JavaScript Features

JavaScript/HTML5 is one of the most important target platform, due to its portability, and ease of deployment.

The major implementations are:

  • SpiderMonkey/Firefox – used in Firefox+MobileBlink/Chrome – used in Chromium, Android, Opera
  • Webkit/Safari – used in Safari+iOS
  • Chakra/Edge – latest version of Microsofts browser

Here is a list of some of the most interesting features, available now or in the near future (as of 2016):

  • WebRTC Data Channels direct communication between peers / clients. Critical in order to make distributed apps. Available in Firefox and Chrome
  • Tail call optimisation makes it easier to implement functional languages on top of the platform. This is coming, – already available in latest dev-snapshot of Chrome and Safari.
  • getUserMedia allows access to camera, and works on major implementations except Safari.
  • WebAssembly makes a better compilation target. Available behind flag in firefox and chrome.
  • Generational garbage collector is a prerequisite for effecient persistent datastructures. This means allocation of short-lived objects are very cheap. This is available in every modern implementation.
  • WebGL enables usage of GPU, and 3D-graphics. This is available in modern implementations.
  • async/await functions make async code much easier to work with. Can be emulated via babel/traceur, and is on its way into browsers.
  • SIMD instructions makes it possible to use some of the parallel processing in the CPU. Some approaches to this is available in dev-releases of FireFox, and Edge, – and also in CrossWalk(Intels chrome-branch for building hybrid mobile apps)
  • Device Orientation and Motion, enables access to movement (useful for VR), and is supported on most implementations (except desktop safari).
  • WebCrypto enables somewhat easy cryptography in the browser. Implemented to a varying degree in all modern implementations.
  • Proper weak references are still not supported in the JavaScript platform, but has a Stage 1 proposal.
  • Typed Arrays allow proper usage of binary data, and is generally supported.
  • WebWorkers enables usage of several cores, and are present in all modern implementations, and transferable objects are now also generally supported. Shared memory is still not implemented(except prototype in firefox).