ChangeNotifierProvider(
create: (context) => BuyValuableNotifier(),
child: OpenContainer(
closedBuilder: (context, action) {
return Container();
},
openBuilder: (context, action) {
return SingleWidget();
},
),
),
so I have this error when call openBuilder: Error: Could not find the correct Provider above this SingleWidget Widget
OpenContainer(
closedBuilder: (context, action) {
return Container();
},
openBuilder: (context, action) {
return ChangeNotifierProvider(
create: (context) => BuyValuableNotifier(),
child: SingleWidget();
},
),
and if I do this I will loose data when openBuilder closes what do I do?