BuildContextEx extension

Extension methods on BuildContext which help working with FactoryContainer.

on

Methods

getContainer() → FactoryContainer

Available on BuildContext, provided by the BuildContextEx extension

Returns closest FactoryContainer in the widget tree. FactoryContainerWidget must be somewhere on top of widget hierarchy.
resolve<T>({String name = ''}) → T

Available on BuildContext, provided by the BuildContextEx extension

Calls FactoryContainer.resolve method on closest FactoryContainer in the widget tree. FactoryContainerWidget must be somewhere on top of widget hierarchy.