Image Network is a package that allows you to render images on the web using CanvasKit without having problems with CORS.
Add image_network
as a dependency in your pubspec.yaml file .
Import Image Network:
import 'package:image_network/image_network.dart';
String imageUrl = "https://scaffoldtecnologia.com.br/wp-content/uploads/2021/10/app-2.png";
ImageNetwork(
image: imageUrl,
height: 150,
width: 150,
duration: 1500,
curve: Curves.easeIn,
onPointer: true,
debugPrint: false,
fullScreen: false,
fitAndroidIos: BoxFit.cover,
fitWeb: BoxFitWeb.cover,
borderRadius: BorderRadius.circular(70),
onLoading: const CircularProgressIndicator(
color: Colors.indigoAccent,
),
onError: const Icon(
Icons.error,
color: Colors.red,
),
onTap: () {
debugPrint("Β©gabriel_patrick_souza");
},
)
Copyright (c) 2021 Gabriel Patrick Souza