Added Auth0 authentication service
| React, website, Auth0
The first step was completing the Next JS + Auth0 Quickstart tutorial.
But something wasn't quite right.
I didn't have my environment variables setup properly on my production server. I'm using Vercel, so it was easy enough to setup. This allowed me to have a local and a production setup which works really well.
After that it was just a little work to create a simple user menu button.
{user ?
<Button variant="contained" onClick={handleUserMenuClick}>{user.nickname}</Button>
: <Button variant="contained">
<Link href="/api/auth/login">
<Typography variant="button" color="inherit">
Login
</Typography>
</Link>
</Button>
}