bf4 / bf4.github.com

jekyll blog on github pages
http://benjaminfleischer.com
MIT License
2 stars 0 forks source link

Put the doc print in an ember jail #2

Closed bf4 closed 9 years ago

bf4 commented 9 years ago

ref: https://github.com/bf4/bf4.github.com/compare/master...emberize_cli_islands

Goal: Replace GoogleSpreadSheetPrinter.js and its calling code with an Ember Component

Inspired by https://speakerdeck.com/tehviking/bring-fun-back-to-js-refactoring-toward-ember

Breaking down of the steps via http://frontside.io/blog/2014/03/06/a-sprinkling-of-ember.html and work done in http://emberjs.jsbin.com/zunedenono/3/edit and http://emberjs.jsbin.com/zikupe/10/edit?html,js,output

Steps

  1. Introduce Ember / Handlebars
  2. Create a placeholder div for the component
  3. Link to source files for Ember, Handlebars, jQuery
  4. Create an Ember component
  5. Make sure you specify the layoutName to match the data-template-name of your handlebars template
  6. Use jQuery to replace your html div with your Ember component.
  7. Be able to run it locally.
  8. Remove dead code

Possibly helpful links: