State of JavaScript: ECMAScript 6 rules

Developers are happy with JavaScript, have mixed feelings about Angular, and are very interested in GraphQL

State of JavaScript: ECMAScript 6 rules
Ambreen Hasan (CC0)

The year 2018 has been a calm one for JavaScript, with ECMAScript 6 remaining the top variant of the scripting language that anchors web development. React has again led the way in front-end frameworks. But 2019 could see some changes, with GraphQL expected to make waves in the data layer.

These and other findings are featured in the “State of JavaScript 2018” report, with feedback based on a survey of more than 20,000 JavaScript developers from 153 countries. They were asked what technologies they were using, what they were happy with and what they wanted to learn.

ECMAScript 6 is the preferred JavaScript version

When it comes to the preferred versions of JavaScript, ECMAScript 6, aka ECMAScript 2015, remains the most popular, followed by TypeScript. Here's how the rest fared, with percentages of respondents who had used a particular JavaScript variant and would do so again:

  • ECMAScript 6: 86.3 percent
  • TypeScript: 46.7 percent
  • Flow, which adds static typing to JavaScript: 10.2 percent
  • Reason: 5.6 percent
  • Elm: 4.3 percent
  • ClojureScript: 2.3 percent

In the 2017 report, plain JavaScript (that is, ECMAScript 5), outpaced TypeScript. But ECMAScript 5 was dropped from this year’s report because many ECMAScript 6 features are now supported natively in browsers and the report’s producers—developers Sacha Greif, Raphael Benitte, and Michael Rambeau—decided to not track both ECMAScript 5 and ECMAScript 6 in the 2018 report.

Redux leads for the JavaScript data layer

The data layer groups all technologies for transmitting and managing data. In this category, many approaches compete to make a tricky problem more approachable, the report stated. Leading this category was Redux, with 47.2 percent of respondents having used it and saying they would again. The three leaders were:

  • Redux: 47.2 percent
  • GraphQL: 20.4 percent
  • Apollo: 11.1 percent

GraphQL, however, could be ready for a steep rise. Nearly 63 percent of respondents had heard of the technology, which is considered an alternative to REST, and wanted to learn it.

React leads for front-end JavaScript frameworks

The survey asked which developers had used a particular framework and would use it again:

But Angular also had 33.8 percent of respondents who reported that they had used it and would not do so again. The framework had similar responses in last year’s survey, with many developers giving a thumbs-down to the first incarnation of the Angular framework and not interested in the second version. Angular currently is on Version 7.

Express leads for back-end JavaScript frameworks

For back-end frameworks, Express led the way, distancing itself a great deal from Next.js.

  • Express: 64.7 percent used it and would do so again
  • Next.js: 8.6 percent
  • Koa: 7.6 percent

A tight race for JavaScript testing tools

Two testing tools—Jest and Mocha—nearly tied as ones developers had used them and would use again, followed closely by Jasmine.

  • Jest: 39.6 percent
  • Mocha: 39.5 percent
  • Jasmine: 28.5 percent
  • Enzyme: 20.3 percent
  • Karma: 18.4 percent
  • Storybook: 15 percent

Electron and React Native lead for JavaScript client development

For mobile and desktop client development, Electron was the leading choice, edging out React Native and native app development, for developers who had used them and wanted to continue:

  • Electron: 19.6 percent
  • React Native: 18.7 percent
  • Native apps: 10.6 percent
  • Cordova: 10.2 percent
  • Ionic: 8.3 percent

Nearly equal numbers of respondents—53.2 percent—had heard of Electron and React Native and wanted to try them.

Other JavaScript tools: languages, APIs, editors

The survey also asked developers what other tools they were using, including languages, browser APIs, and text editors.

For languages, Python led the way, with 6,262 respondents using it. Following it were PHP (5,559 respondents), Java (4,605 respondents), and C# (3,779 respondents).

For browser APIs, service workers were used by more than 8,843 respondents, slightly ahead of progressive web apps (PWAs), with 8,792 backers. Web components were used by a 5,304 respondents.

The most-popular build tools were Webpack, used by 17,104 respondents, and Gulp, used by 7,276 respondents.

Microsoft’s Visual Studio Code led the way among editors, used by more than 14,492 respondents, followed by Sublime Text, with about 4,478 respondents, which was slightly ahead of Vim, backed by 4,467 respondents.

JavaScript is headed in the right direction

Respondents also strongly agreed, with a 51.2 percent result, that JavaScript was headed in the right direction. And 57 percent strongly agreed when asked if they enjoy building JavaScript apps.

Copyright © 2018 IDG Communications, Inc.