Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Ember Build Tools Showdown

Eric Berry
November 26, 2013

Ember Build Tools Showdown

Covers the different build tool options for Ember and evaluates the pros and cons of each.

Video at http://www.youtube.com/watch?v=b1VfmeXznfk&feature=c4-overview&list=UU7zhgq6ntpbl0tgOsTTsenw

Download source code (demos) at https://github.com/cavneb/build_tools_showdown

Eric Berry

November 26, 2013
Tweet

More Decks by Eric Berry

Other Decks in Technology

Transcript

  1. Yeoman + Ember Generators • Get up and running very

    quickly • CommonJS • Ember Generators • Test with Mocha + Karma (or other) • Actively maintained
  2. Yeoman + Ember Generators $ npm install -g generator-ember $

    mkdir <appname> && cd <appname> $ yo ember $ grunt server
  3. Yeoman + Ember Generators • Built-in Generators • Test Framework

    (Karma) • Grunt • Based on Ember Starter Kit • Bower support • Generators are terrible • Global namespace • Gruntfile is huge and difficult to follow • Folder structure not complete (missing components/helpers) • Does not support subfolders in routes (controllers too?) • TONS of cleanup to do initially Pros Cons
  4. Brunch.io (Yet Another Ember Brunch*) • Compile scripts, templates, styles,

    lints them • Wraps scripts in CommonJS/AMD • Generates source maps • Minify code and optimize images • Bower Integration • Generators with Loom • Test with qUnit + Testem • Build for production • Automated gzip of assets • Auto Reload • Less • CoffeeScript
  5. Brunch.io (Yet Another Ember Brunch*) $ npm install -g brunch

    $ brunch new gh:cavneb/yet-another- ember-brunch <appname> $ cd <appname> $ cake server
  6. • Generators • Very simple (single config file) • Easy

    to understand • CoffeeScript? • Bower integration is VERY good • Environment Vars!!! • Difficult to tie into build process • Need to rely on good skeletons • Not a lot of community support • Weird way of wrapping transpired CommonJS to AMD. • CoffeeScript (or use another skeleton) • Relies on global namespace Pros Cons Brunch.io (Yet Another Ember Brunch*)
  7. Ember Tools • Super easy • CommonJS • Generators •

    Very light footprint (easy to add to 
 existing project)
  8. Ember Tools $ npm install -g ember-tools $ ember create

    <appname> $ cd <appname> $ ember build —watch $ open index.html
  9. • Generators • Minimalist approach • Applies best practices •

    Easy to integrate into backend app (e.g. Django or Rails) • Not actively maintained *** • Hard decency on Ember file locations • No build for production • No default setup for tests. • There’s no build process to tie into (e.g. Grunt) Pros Cons Ember Tools *** Ryan says he will start work on it again soon
  10. Ember App Kit • Sane project structure • ES6 module

    transpiler support • Module system-aware resolver • Transparent project compilation and minification for easy deploys via Grunt • Package management via Bower • Optional support for CoffeeScript, SASS, LESS or Stylus • Testing via QUnit, Ember Testing and Karma • Linting via JSHint (including module syntax) @stefanpenner
  11. • ES6 • Generators • Core team supported • Applies

    and enforces best practices • Production builds • Test framework integrated • It is changing a lot (but starting to stabilize) • Gruntfile is massive (see tasks folder) • Development builds to a ‘tmp’ folder • More difficult to add to existing projects • Complicated • Grunt has weirdness in relation to new file watching • Generators aren’t quite flushed out yet Pros Cons Ember App Kit
  12. Ember App Kit • Everything that Ember App Kit provides

    (except tests) • Integrated into Rails Asset Pipeline • Uses Rails Generators • Automatic environment-based building • Warm fuzzies for all! for Rails
  13. Yeoman Brunch.io Ember
 Tools Ember" App Kit Ember App" Kit

    for Rails Generators Kindof Yes Yes Yes Yes ES6 - - - Yes Yes Custom Tasks Yes - - Yes Yes (via Rails) Production Builds Yes Yes - Yes Yes Ease of Use Moderate Excellent Excellent Moderate Excellent Support/Activity Excellent Moderate Moderate Excellent Excellent Testing Yes Yes - Yes -