The problem is you're returning a different type data via this // this is a json decoded data, not String return json.decode(response.body); and mentioned the return data type String in your Generic Data type for you Future. is that correct? hmm this should work : final List sublist = el.map((val) => Match.fromJson(val)).toList(); I just used it this way now but it keep giving me. rev2023.7.7.43526. How can I remove a mystery pipe in basement wall and floor? The neuroscientist says "Baby approved!" I'm getting this error type 'list' is not a subtype of type 'string' and in debug. To subscribe to this RSS feed, copy and paste this URL into your RSS reader. That should be enough for most purposes in Dart. QGIS does not load Luxembourg TIF/TFW file. } This question does not appear to be about programming within the scope defined in the help center. why my list model show this error : type 'List' is not a subtype of type 'List'? All these "LIVING", "SOFAS", "BEDROOM" objects are dynamic, sometime they comes or sometime not. I want to update image from listofTaskNotApprove class which it will pass the object of documentsnapshot into the EditTaskNotApprove. 587), The Overflow #185: The hardest part of software is requirements, Starting the Prompt Design Site: A New Home in our Stack Exchange Neighborhood, Temporary policy: Generative AI (e.g., ChatGPT) is banned, Testing native, sponsored banner ads on Stack Overflow (starting July 6), type 'List' is not a subtype of type 'List', List is not a subtype of List