I have widget (FirstWidget) and 2 providers to this widget on 2 different pages.
First screen:
BlocProvider<FirstBloc>(
create: (context) => FirstBloc()
child: FirstWidget(),
)
Second screen:
BlocProvider<SecondBloc>(
create: (context) => SecondBloc()
child: FirstWidget(),
)
How to manage specific bloc in this widget using e.g. blocbuilder?
For example on first screen I wanna use in this widget FirstBloc and on second screen SecondBloc but this widget is in one file. What should i write in BlocBuilder? I tried BlocBuilder<dynamic, dynamic>
but its not working.