I want to build a package for Flutter and Dart, but I don't have any previous experience with package development. I am not sure how to create the package. Should I use
flutter create --template=package
or
dart create -t package
I want support for both Flutter and Dart.
I looked at the Flutter documentation on creating packages, but I couldn't understand if it would create a package with Flutter only support, or both Flutter and Dart support.
CodePudding user response:
First, use the following command to check if your package meets all the requirements to publish the package.
dart pub publish --dry-run
Once you are sure that your package is ready to deploy on pub dev run this command:
dart pub publish