Dart Provider: not available at the immediate child
问题 @override Widget build(BuildContext context) { return BlocProvider<HomeBloc>( create: (context) { return HomeBloc(homeRepo: HomeRepository()); }, child: BlocProvider.of<HomeBloc>(context).state is HomeStateLoading ? CircularProgressIndicator() : Container()); } I am confused with the error: BlocProvider.of() called with a context that does not contain a Bloc of type HomeBloc. No ancestor could be found starting from the context that was passed to BlocProvider.of<HomeBloc>(). Didn't I just