GroupsPage.fromJson constructor

GroupsPage.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory GroupsPage.fromJson(Map<String, dynamic> json) {
  final list = json['groups'] as List<dynamic>? ?? [];
  return GroupsPage(
    groups: list.whereType<Map<String, dynamic>>().map(Group.fromJson).toList(),
    continuationToken: json['continuation_token'] as String?,
  );
}