getting
Error :
/*
dynamic AmplifyStorageS3()
package:my_budget_app/main.dart
AmplifyStorageS3 isn't a type.
Try correcting the name to match an existing type
*/
CodePudding user response:
I have 3 ideas.
1: In package import import 'package:amplify_storage_s3/amplify_storage_s3.dart';
add "as ampl" to the end and then you will have something like this:
import 'package:amplify_storage_s3/amplify_storage_s3.dart' as ampl;
And then write:
ampl.AmplifyStorageS3 storage = ampl.AmplifyStorageS3();
2: Hold ctrl and left click on the imported package, find this class in the package and find out what's wrong.
3: Check your pubspec.yaml and so on for minimum requirements:
environment:
sdk: ">=2.12.0 <3.0.0"