ComponentCodec<T>.stateful constructor
const
ComponentCodec<T>.stateful ({})
Create a codec for a component that needs to serialize state.
Implementation
const ComponentCodec.stateful({
required this.typeStr,
required T Function(Object?) decode,
required Object? Function(T) encode,
}) : _decode = decode,
_encode = encode,
_create = null;