SuggestModel.fromJson constructor
Implementation
factory SuggestModel.fromJson(Map<String, dynamic> json) {
return SuggestModel(
found: json['found'] as int?,
query: json['query'] as String?,
suggestions: (json['suggestions'] as List?)
?.whereNotNull()
.map((e) => SuggestionMatch.fromJson(e as Map<String, dynamic>))
.toList(),
);
}