singleton 0.0.3-nullsafety
singleton: ^0.0.3-nullsafety copied to clipboard
Singleton make singleton implementation less hassle, and also make it more friendly to tests.
We analyzed this package 11 days ago, and awarded it 150 pub points (of a possible 160):
10/10 points: Provide a valid pubspec.yaml
5/5 points: Provide a valid README.md
5/5 points: Provide a valid CHANGELOG.md
10/10 points: Use an OSI-approved license
Detected license: MIT.
10/10 points: 20% or more of the public API has dartdoc comments
15 out of 22 API elements (68.2 %) have documentation comments.
Some symbols that are missing documentation: singleton, singleton.Singleton.key, singleton.SingletonKey, singleton.SingletonKey.SingletonKey.new, singleton.SingletonKey.name.
10/10 points: Package has an example
20/20 points: Supports 6 of 6 possible platforms (iOS, Android, Web, Windows, macOS, Linux)
-
✓ Android
-
✓ iOS
-
✓ Windows
-
✓ Linux
-
✓ macOS
-
✓ Web
WASM-ready: This package is compatible with runtime wasm. See https://dart.dev/web/wasm for details.
40/50 points: code has no errors, warnings, lints, or formatting issues
INFO: Use the generic function type syntax in 'typedef's.
lib/src/singleton.dart:7:11
╷
7 │ typedef T SingletonFactory<T>();
│ ^^^^^^^^^^^^^^^^
╵
To reproduce make sure you are using the lints_core and run dart analyze lib/src/singleton.dart
INFO: Statements in an if should be enclosed in a block.
lib/src/singleton.dart:215:7
╷
215 │ throw StateError("Double register for singleton $T");
│ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
╵
To reproduce make sure you are using the lints_core and run dart analyze lib/src/singleton.dart
10/10 points: All of the package dependencies are supported in the latest version
| Package | Constraint | Compatible | Latest | Notes |
|---|---|---|---|---|
async |
^2.5.0-nullsafety.3 |
2.13.1 | 2.13.1 | |
meta |
^1.3.0-nullsafety.6 |
1.19.0 | 1.19.0 |
Transitive dependencies
| Package | Constraint | Compatible | Latest | Notes |
|---|---|---|---|---|
collection |
- | 1.19.1 | 1.19.1 |
To reproduce run dart pub outdated --no-dev-dependencies --up-to-date --no-dependency-overrides.
10/10 points: Package supports latest stable Dart and Flutter SDKs
20/20 points: Compatible with dependency constraint lower bounds
pub downgrade does not expose any static analysis error.
Analyzed with Pana 0.23.18, Dart 3.13.1.
Check the analysis log for details.