watch<T> method

T watch<T>()

The T of the nearest provider of one above this context, which is rebuilt each time it changes, as long as its builds watch it. A ProviderNotFoundException if there is none, unless T is nullable: then null.

Implementation

T watch<T>() => Provider.of<T>(this);