requireData property
T
get
requireData
Implementation
T get requireData {
if (hasData) return data!;
if (hasError) Error.throwWithStackTrace(error!, stackTrace!);
throw StateError('Snapshot has neither data nor error');
}