You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi. I get this error using your code, but with a newer version of the flutter_bloc: ^0.21.0
I downgraded to 0.11.0 and it doesn't return the same error.
Update:
I just realized that this is just a proof of concept, but if you want to update the code to the current version of the flutter_bloc, you might want to change _MyHomePageState class to this: class _MyHomePageState extends State<MyHomePage> { @override Widget build(BuildContext context) { return BlocProvider<CounterBloc>( builder: (context) => CounterBloc(), child: CounterWidget(widget: widget), ); } // BlocProvider also handles disposing the CounterBloc automatically }
The text was updated successfully, but these errors were encountered:
Hi. I get this error using your code, but with a newer version of the flutter_bloc: ^0.21.0
I downgraded to 0.11.0 and it doesn't return the same error.
Update:
I just realized that this is just a proof of concept, but if you want to update the code to the current version of the flutter_bloc, you might want to change _MyHomePageState class to this:
class _MyHomePageState extends State<MyHomePage> { @override Widget build(BuildContext context) { return BlocProvider<CounterBloc>( builder: (context) => CounterBloc(), child: CounterWidget(widget: widget), ); } // BlocProvider also handles disposing the CounterBloc automatically }
The text was updated successfully, but these errors were encountered: