Contextualizing State
summary
Argues that Ember can have React‑style component context to pass state to a subtree without global services, and ships an add‑on providing @provide/@consume decorators plus provider/consumer components. Demonstrates a select and an accessible form‑field built with context, hits an infinite‑render bug from tracked getters, fixes it by splitting contexts and using stable refs, proposes test helpers to inject contexts, and reports the add‑on already runs in production UIs.
AI-written summary · about
chapters (12)
- 0:00Introduction and background
- 2:33What is context in frameworks
- 7:09State sharing patterns in Ember
- 10:22Thoughts on Ember context
- 13:08Context in action with examples
- 17:40Building composable components
- 21:55Accessibility with context
- 23:42Debugging context issues
- 26:10Other use cases for context
- 27:54When not to use context
- 28:55Testing with context
- 30:20Ember context add-on and RFC
