Answers for "flutter call provider in initstate"

0

flutter call provider in initstate

@override
void initState() {
    super.initState();

    WidgetsBinding.instance.addPostFrameCallback((timeStamp) {
      auth = Provider.of<Auth>(context, listen: false);
    });
}
Posted by: Guest on April-19-2021

Browse Popular Code Answers by Language