isReadingDom property

bool get isReadingDom

Indicates to users that we are currently processing items in the read queue.

Client can optimize calls by not adding into the queue but instead is safe to execute the read synchronously.

Example: if (domService.isReadingDom) { readClientMetrics(); } else { domService.scheduleRead(readClientMetrics); }

Implementation

bool get isReadingDom => (_state == DomServiceState.Reading);