Is there any good practice how to give user JWT token after provider send him back? Give it to user as cookie on redirect to home page? Put it in header? As far as I know I need javascript to save token into LocalStorage/SessionStorage.
right now i'm using
first
$currentUser = JWTAuth::parseToken()->authenticate();
$request->session()->put('user_id', $currentUser->id);
after callback
$currentUser = $request->session()->get('user_id', 'default');
$request->session()->forget('user_id');
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community