Answers for "error = Converting object to an encodable object failed: Instance of 'SendCart'"

0

error = Converting object to an encodable object failed: Instance of 'SendCart'

class LinkItem {
  final String name;
  final String url;

  LinkItem({this.name, this.url});

  LinkItem.fromJson(Map<String, dynamic> json)
      : name = json['n'],
        url = json['u'];

  Map<String, dynamic> toJson() {
    return {
      'n': name,
      'u': url,
    };
  }
}
Posted by: Guest on May-15-2021

Code answers related to "error = Converting object to an encodable object failed: Instance of 'SendCart'"

Browse Popular Code Answers by Language