Converting dart T object to json
dart
T
json
Map<String, dynamic> jsonEncode(T value) => jsonEncodeRaw(dartDecodeRaw(value).toList());