Notes from the 'Ember in Action' talk
Speaker
- Justing Giancoloa
- Github profile
- Twitter profile
- Lanyrd profile
Summary
What does an Ember app actually look like in practice? How do features like computed properties, data bindings, and state machine-based structure come together to make a real application?
In this talk we will explore a medium-sized Ember app. We will go over high-level app structure and investigate specific techniques and idioms that commonly appear. The application source will be available on Github so that you can follow along in your favorite editor or dig in afterwards when you want to refresh your memory.
By the end you should have a practical sense of what makes the framework useful and what makes writing apps with Ember so enjoyable.
Goal
- Show what building an app feels like
- Focus on how things fit together
- Provide a roadmap for finding answers
This talk was very code heavy. Find the code samples on github
What are we building
- Clone of Peepcode's backbone I & II screencast app
- https://peepcode.com/products/backbone-js
- https://peepcode.com/backbone-ii
Approach to building ember apps
Models
- Domain logic
- Hold persistant data
Controllers
- present model data to views
- hold transiet data
Views
- Manage browser interaction
- Can be used for application level events
Router
- Coordinates app state with URL
- Coordinates creation, connection of app components
What I like to do
- Work from the outside in
- Start from UI
- Build downwards into internal components
- Following convenitions
Steps
- I missed the first 2 steps
- I missed the first 2 steps
- Pull in our data
- Render library content
- Add playlist controller
- Queueing albums
- Track listings
- First computed property
- Current Track
- Current Track and current album styling
- Add dequeue action
- Prev and next
- Music
Recap
- Less than 200 SLOC (JS + templates)
- Better abstractions
- Harder to ruin apps
Thanks for reading! Follow me on Twitter and/or G+ for more.
See something wrong or got something to add/change? Fork this git repo and send me a pull request
If you particularly enjoy my work, I appreciate donations given with Gitcoin.co