0

enter image description hereUsing Hasura with flutter, getting the following errors, Graphql version ^3.0.0

{
    "resource": "/D:/example_hasura1/lib/county.dart",
    "owner": "dart",
    "code": "argument_type_not_assignable",
    "severity": 8,
    "message": "The argument type 'Widget Function(QueryResult, {refetch: void Function()})' can't be assigned to the parameter type 'Widget Function(QueryResult, {fetchMore: dynamic Function(FetchMoreOpti[![enter image description here][1]][1]ons), refetch: Future<QueryResult> Function()})'.",
    "source": "dart",
    "startLineNumber": 24,
    "startColumn": 9,
    "endLineNumber": 24,
    "endColumn": 347,
    "tags": []
}
user2132225
  • 119
  • 1
  • 1
  • 8
  • Please check the question guidelines and improve your question: https://stackoverflow.com/help/how-to-ask – J. S. Mar 03 '20 at 09:24

1 Answers1

2

instead of: builder: (QueryResult result, {VoidCallback refetch}) { ... }

add a third parameter like this: builder: (QueryResult result, {VoidCallback refetch, FetchMore fetchMore}) { ... }

and I can see that you're not checking errors. But if you do, then make sure to change it from .error to .hasException

Hope it works

Nirmesh
  • 36
  • 1