toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() => {
      if (title != null) "title": title,
      if (body != null) "body": body,
      if (icon != null) "icon": icon,
    };