Contextual Components in React
Contextual Components are one of my favorite features in Ember. They allow you to expose components pre-wired with state and actions as part of a component's public API, without having to directly expose that state or those actions. This same pattern can be applied to React components using the Render Props pattern. Let's look at an example to make this more concrete. If you're coming from Ember, check out this example on Ember Twiddle, as the rest of this post will be implementing the equivalent in React.