SHARE
TWEET

Untitled

wildanfuady Nov 14th, 2019 91 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. actions: <Widget>[
  2.           IconButton(
  3.             icon: Icon(Icons.lock_open, semanticLabel: "Logout",),
  4.  
  5.             onPressed: () async {
  6.               // hapus shared prefs login
  7.               final prefs = await SharedPreferences.getInstance();
  8.               prefs.remove('login');
  9.               // redirect page/route ke login
  10.               Navigator.push(
  11.                 context,
  12.                 MaterialPageRoute(builder: (context) => Login()),
  13.               );
  14.             },
  15.           ),
  16.         ],
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top