Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Ember ATX: Ember.Evented
Search
timgthomas
July 24, 2015
Technology
0
120
Ember ATX: Ember.Evented
Lightning talk about one of my favorite Ember mixins, Ember.Evented!
timgthomas
July 24, 2015
Tweet
Share
More Decks by timgthomas
See All by timgthomas
Living Style Guides: Bringing Designers and Developers Together
timgthomas
0
230
Icons and the Web: Symbols of the Modern Age
timgthomas
0
170
Constructing Modern UIs with SVG
timgthomas
0
190
Browser Invasion: Desktop Apps and the Web
timgthomas
0
160
Mind the Gap: Bringing Designers and Developers Together
timgthomas
0
130
Zero to App Store: A Hybrid App’s Tale
timgthomas
1
150
Chocolate-Covered Vegetables: Tasty Workflows with Broccoli
timgthomas
0
130
Ember ATX: Components
timgthomas
0
85
Chocolate-Covered Vegetables: Tasty Workflows with Broccoli
timgthomas
0
380
Other Decks in Technology
See All in Technology
ペアーズにおけるAIエージェント 基盤とText to SQLツールの紹介
hisamouna
2
1.6k
M&Aで拡大し続けるGENDAのデータ活用を促すためのDatabricks権限管理 / AEON TECH HUB #22
genda
0
230
たまに起きる外部サービスの障害に備えたり備えなかったりする話
egmc
0
400
ハッカソンから社内プロダクトへ AIエージェント「ko☆shi」開発で学んだ4つの重要要素
sonoda_mj
6
1.6k
NIKKEI Tech Talk #41: セキュア・バイ・デザインからクラウド管理を考える
sekido
PRO
0
210
Building Serverless AI Memory with Mastra × AWS
vvatanabe
0
500
SQLだけでマイグレーションしたい!
makki_d
0
1.2k
AR Guitar: Expanding Guitar Performance from a Live House to Urban Space
ekito_station
0
150
"人"が頑張るAI駆動開発
yokomachi
1
130
フルカイテン株式会社 エンジニア向け採用資料
fullkaiten
0
9.9k
アラフォーおじさん、はじめてre:Inventに行く / A 40-Something Guy’s First re:Invent Adventure
kaminashi
0
140
ハッカソンから社内プロダクトへ AIエージェント ko☆shi 開発で学んだ4つの重要要素
leveragestech
0
120
Featured
See All Featured
Design in an AI World
tapps
0
100
Imperfection Machines: The Place of Print at Facebook
scottboms
269
13k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
0
88
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
0
250
Context Engineering - Making Every Token Count
addyosmani
9
550
Git: the NoSQL Database
bkeepers
PRO
432
66k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.3k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
1.9k
Designing Powerful Visuals for Engaging Learning
tmiket
0
190
Un-Boring Meetings
codingconduct
0
160
30 Presentation Tips
portentint
PRO
1
170
How to build a perfect <img>
jonoalderson
0
4.7k
Transcript
Hi!
@timgthomas
Scenario
// models/item.js export default Ember.Object.extend({ actions: { save() { this.set('savedAt',
new Date()); } } }); // components/show-item.js export default Ember.Component.extend({ itemSaved: function() { // ... }.observes('item.savedAt') });
”Data Down, Actions Up“
Ember.Evented
// models/item.js export default Ember.Object.extend(Ember.Evented, { actions: { save() {
this.trigger('saved'); } } }); // components/show-item.js export default Ember.Component.extend({ init() { this._super(); this.get('item').on('saved', this.itemSaved); } });
// controllers/list.js export default Ember.Controller.extend(Ember.Evented, { actions: { save() {
this.trigger('saved'); } } }); // controllers/item.js export default Ember.Controller.extend({ init() { this._super(); this.get('controllers.list').on('saved', () => {}); } });
Route Hierarchy Gotcha!
let controller = this.get('controllers.foo'); controller.trigger('foo'); controller.trigger('foo', 'bar'); controller.on('foo', () =>
{}); controller.off('foo', () => {}); controller.one('foo', () => {}); controller.has('foo');
bit.ly/ember-evented
Thanks!