riverpod-patterns — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited riverpod-patterns (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
import 'package:riverpod_annotation/riverpod_annotation.dart';
part 'user_provider.g.dart';
// Simple provider (auto-disposed by default)
@riverpod
Future<User> currentUser(Ref ref) async {
final repo = ref.watch(userRepositoryProvider);
return repo.getCurrentUser();
}
// Notifier (state management with methods)
@riverpod
class UserController extends _$UserController {
@override
Future<User> build() async {
final repo = ref.watch(userRepositoryProvider);
return repo.getCurrentUser();
}
Future<void> updateName(String name) async {
state = const AsyncLoading();
state = await AsyncValue.guard(() =>
ref.read(userRepositoryProvider).updateName(name)
);
}
}
// Family provider (parameterized)
@riverpod
Future<Product> productDetail(Ref ref, String productId) async {
final repo = ref.watch(productRepositoryProvider);
return repo.getById(productId);
}@riverpod
UserRepository userRepository(Ref ref) {
final dio = ref.watch(dioProvider);
return UserRepositoryImpl(dio);
}class UserScreen extends ConsumerWidget {
@override
Widget build(BuildContext context, WidgetRef ref) {
final userAsync = ref.watch(currentUserProvider);
return userAsync.when(
data: (user) => Text(user.name),
loading: () => const CircularProgressIndicator(),
error: (e, st) => ErrorWidget(e, onRetry: () => ref.invalidate(currentUserProvider)),
);
}
}// Sadece name degistiginde rebuild
final name = ref.watch(userControllerProvider.select((s) => s.value?.name));ref.listen(userControllerProvider, (prev, next) {
next.whenOrNull(
error: (e, _) => ScaffoldMessenger.of(context).showSnackBar(SnackBar(content: Text('$e'))),
);
});~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.