RxMap<K, V> constructor
- @Deprecated('Collections, Futures and Streams will no longer be ' 'supported by this package as they violate the ASP standard. ' 'It is better to use a pure [Atom] synchronously ' 'to understand the flow of reactivity.')
Creates a RxMap that may be initialized with a map.
{@tool snippet}
final map = RxMap({'name': 'jacob'});
{@end-tool}
Implementation
@Deprecated('Collections, Futures and Streams will no longer be '
'supported by this package as they violate the ASP standard. '
'It is better to use a pure [Atom] synchronously '
'to understand the flow of reactivity.')
RxMap([Map<K, V>? map, String? key]) {
this.key = key ?? 'RxList:$hashCode';
if (map != null) {
_map = map;
} else {
_map = {};
}
}