isSubtype<S, T> function
Determines whether S is a subtype of T or T?.
isSubtype<Calendar, IInspectable>(); // true
isSubtype<IUnknown, IInspectable>(); // false
Implementation
bool isSubtype<S, T>() => <S>[] is List<T> || <S>[] is List<T?>;