
Flutter/Riverpod
Flutter) Riverpod Consumer 사용하기 - 5
class MyApp extends ConsumerWidget { const MyApp({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { //ref를 사용해 프로바이더 구독하기 final counter = ref.watch(counterProvider); ref.listen(counterProvider, (previousState, newState) { print("The new value is $newState"); }); return MaterialApp( home: Scaffold( appBar: AppBar(title: Text("Riverpod Study")), body: Center( child: Column..