client/src/utils/auth.js
//check to see if 'token' is expired
check to see if 'token' is expired
check to see if ' token ' is expired
isTokenExpired(token) {
    const decoded = decode(token);
    if (decoded.exp < (Date.now()/1000)) {
      localStorage.removeItem('id_token');
      return true;
    }
    return false;
  }
isTokenExpired ( token ) { const decoded = decode ( token ) ; if ( decoded . exp < ( Date . now ( ) / 1000 ) ) { localStorage . removeItem ( 'id_token' ) ; return true ; } return false ; }
check to see if 'token' is expired
check to see if ' token ' is expired