Features and bugs #
Please file feature requests and bugs at the issue tracker.
- Allow parsing files with default-package entries and metadata. A default-package entry has an empty key and a valid package name as value. Metadata is attached as fragments to base URIs.
- Fix usage of SDK constants.
- Set max SDK version to <3.0.0.
- Removed unneeded dependency constraint on SDK.
- Update SDK constraint to be 2.0.0 dev friendly.
- Fix test to not write to sink after it's closed.
- Public API marked stable.
- Strong mode fixes.
- Invalid test cleanup (to keep up with changes in
- Syntax updates.
- Initial implementation.
Use this package as a library
1. Depend on it
Add this to your package's pubspec.yaml file:
dependencies: package_config: ^1.1.0
2. Install it
You can install packages from the command line:
$ pub get
$ flutter pub get
Alternatively, your editor might support
pub get or
flutter pub get.
Check the docs for your editor to learn more.
3. Import it
Now in your Dart code, you can use:
import 'package:package_config/discovery.dart'; import 'package:package_config/discovery_analysis.dart'; import 'package:package_config/packages.dart'; import 'package:package_config/packages_file.dart';
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
We analyzed this package on Jan 19, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:
- Dart: 2.7.0
- pana: 0.13.4
lib/discovery.dart. (-9.08 points)
lib/discovery.dart reported 19 hints, including:
line 34 col 12: Unnecessary new keyword.
line 38 col 17: Unnecessary new keyword.
line 57 col 27: Unnecessary new keyword.
line 58 col 12: Unnecessary new keyword.
line 63 col 10: Unnecessary new keyword.
lib/packages_file.dart. (-5.36 points)
lib/packages_file.dart reported 11 hints, including:
line 65 col 23: Unnecessary new keyword.
line 72 col 9: Unnecessary new keyword.
line 114 col 11: Unnecessary new keyword.
line 126 col 18: Unnecessary new keyword.
line 133 col 13: Unnecessary new keyword.
lib/src/util.dart. (-4.41 points)
lib/src/util.dart reported 9 hints, including:
line 46 col 11: Unnecessary new keyword.
line 50 col 11: Unnecessary new keyword.
line 55 col 11: Unnecessary new keyword.
line 63 col 11: Unnecessary new keyword.
line 67 col 11: Unnecessary new keyword.
Fix additional 4 files with analysis or formatting issues. (-4.97 points)
Additional issues in the following files:
Maintain an example. (-10 points)
Create a short demo in the
example/ directory to show how to use this package.
Common filename patterns include
package_config.dart. Packages with multiple examples should provide
For more information see the pub package layout conventions.
The package description is too short. (-3 points)
Add more detail to the
description field of
pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.