isExpired property

Future<bool> isExpired

Returns true if cache does not exist, false if it exists but maxAge is null; otherwise compares the cache's age to maxAge.

Implementation

Future<bool> get isExpired async =>
    hasExpired(await cache.lastModified, maxAge);