I am adding a compass to my flutter project and I usedthis package. but when I changed the compass image to my own, it shows the default image for a second. here is my code
SmoothCompass(
rotationSpeed: 200,
height: 300,
width: 300,
compassAsset: Image.asset(
"assets/images/compass1.png",
height: 200,
width: 200,
),
)
CodePudding user response:
Fixed: this was the issue in compass package previous version this issue is now resolved in the latest version check it out smooth_compass: ^2.0.4
- remove previous version from pubspec.yaml.
- execute flutter clean & flutter pub get
- execute
flutter pub add smooth_compass
- now run your flutter app