TextContent.fromJson constructor
Implementation
factory TextContent.fromJson(Map<String, dynamic> json) {
return TextContent(
format: TextFormat.values.firstWhere(
(e) => e.toString().split('.').last == json['format'],
orElse: () => TextFormat.plain,
),
value: json['value'] as String,
);
}