Home > Back-end >  The return type 'Future<dynamic>' isn't a 'Widget', as required by th
The return type 'Future<dynamic>' isn't a 'Widget', as required by th

Time:02-06

I'm trying to make an image text recognition app where I pass image to methods for getting the result as recognized text, but I get the Future builder error while passing the image through the navigator push routing for a methos passing.

My Code is :

enter image description here

This is giving the error

enter image description here

enter image description here

CodePudding user response:

for Navigator.push() & Navigator.pop() we use these to go to other files like classes from one class or file . here we're passing parameters as image file within methods within one class. So, in this case Navigator.push() isn't working out. Just the name of method with parameter would work like these scanText(image!);

  • Related