exists<T extends Object?> method
Valids if the instance of T with or without id given exists.
Implementation
bool exists<T extends Object?>([String? id]) {
final instanceKey = ReactterInstance.generateKey<T?>(id);
return _instancesByKey[instanceKey]?.instance != null;
}