I have been working with Blocs and I always navigate in the same way:
Navigator.of(context).push(MaterialPageRoute(builder: (_) {
return BlocProvider(
create: (context) => MovieListBloc(),
child: MovieListView(),
);
}))
And now, I'm using a Cubit in a similar way, but getting the error on navigate about "Could not find the correct Provider above BlocBuilder.
Navigator.of(context).push(MaterialPageRoute(builder: (_) {
return BlocProvider(
create: (context) => MovieListCubit(),
child: MovieListView(),
);
}))
Am I missing something here, why can't they be used interchangeably?
I swapped the Bloc for a Cubit, and now I can't navigate.