lykhonis / image_crop

A flutter plugin to crop image on iOS and Android.
Apache License 2.0
328 stars 202 forks source link

In Crop() image expecting ImageProvider insted of Image #46

Open shashank1800 opened 4 years ago

shashank1800 commented 4 years ago

Container( child: Crop( key: cropKey, image: Image.file(_image), aspectRatio: 1, ), ),

The argument type 'Image' can't be assigned to the parameter type 'ImageProvider'.dart(argument_type_not_assignable)

wrbl606 commented 4 years ago

Hey, just use FileImage instead of Image.file.

Source: https://api.flutter.dev/flutter/widgets/Image-class.html

shashank1800 commented 4 years ago

Thanks👍

On Mon, 16 Mar, 2020, 7:07 PM Marcin Wróblewski, notifications@github.com wrote:

Hey, just use FileImage instead of Image.file.

Source: https://api.flutter.dev/flutter/widgets/Image-class.html

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/lykhonis/image_crop/issues/46#issuecomment-599540545, or unsubscribe https://github.com/notifications/unsubscribe-auth/AH26VJPWXJVGSITM3EHBTRDRHYTSRANCNFSM4K7VUQHA .