onTurnStart property
A synchronous stream that fires when the VM turn has started, which means that the inner (managed) zone has not executed any microtasks.
Note:
- Causing any turn action, e.g., spawning a Future, within this zone will cause an infinite loop.
Implementation
@override
Stream get onTurnStart {
if (_onTurnStartController == null) {
_onTurnStartController = StreamController.broadcast(sync: true);
}
return _onTurnStartController!.stream;
}