-2

I've read the flutter-bloc documentation and I really have no idea what to do anymore. Someone to help?

error bloc provider

Ilgner
  • 21
  • 2

2 Answers2

0

Probably you didn't import the Bloc package into this file.

0

Try create: instead of bloc:

BlocProvider<UserBloc>(
      create: (context) => UserBloc(),
      child: Container(),
    );
Xuuan Thuc
  • 2,340
  • 1
  • 5
  • 22