20Jul2015

Application Development: Babel transpiler to use ES6 today

ECMAScript 6 standard is coming. As a next generation of JavaScript, it would be the most significant change in front-end Application Development in near future. BTW, new official label of standard is ES2015 for now. So, don’t be confused at line of terms. There is the same. ES2015 is not production ready approach, because it’s not supported officially by majority of the web browsers. On the other hand, ES2015 is very hot and too sexy to wait for official release date. Besides, it would be better to have ES6 skills for your front-end developer career. Well-known technologies like CoffeeScript pale into insignificance. A lot of smart software architects and CTO’s decide to design their new from-scratch client-side applications with perspective to be developed and supported in terms of ES6 standard. There would be the problem how to deal with such code right now. Regular solution is to use some tool to translate ES6 code into regular JavaScript, like we are doing in case of CoffeeScript or TypeScript. Babel [https://babeljs.io] is the most famous solution for that.

ES6 new features

So, what does it make ES6 standard to produce a lot of hype about. There is an arrow operator => introduces syntax sugar for function creation similar to CoffeeScript. There are classes with constructors, inheritance, static methods and other real OOP features. That is much better than old-school prototype-based pseudo-OOP of regular JavaScript. There is added built-in string interpolation like it’s used in other programming languages for decades already.

Read more
05Jul2015

Application Development: HTML5 build tools

Nowadays, HTML5 applications are complicated enough to treat them like something more than a set of static and dynamic pages. Web Application Development of client side solutions is a full process like any other software development. So, it needs some kind of build tool to process LESS or SASS sources of stylesheets, translate CoffeeScript, TypeScript or any other language that compiles into JavaScript, apply linters and run unit tests, join and minify the code. Automation of all these duties is a must-have practice of any professional team like Iflexion. There are already several approaches available and widely used.

Grunt

Grunt [http://gruntjs.com] was the first in a row of JavaScript build tools. It’s based on the set of tasks. Basically, grunt is a task runner. The tasks should be described in Gruntfile.js file as declarative configuration composed in JSON format. There are a lot of plugins to automate almost any set of actions. Grunt is based on node.js. Main module and its plugins are npm packages.

Read more