Where to clear localStorage when using @auth0/nextjs-auth0?

I want to be able to clear localStorage whenever a user logs out. I’m wondering if the package @auth0/nextjs-auth0 has a central place to handle the clearing of local storage?

I tried to implement the logout function but it can’t clear the localStorage since its server side.

Here is the code that I tried:

export default handleAuth({
import { handleAuth, handleLogout } from "@auth0/nextjs-auth0";

export default handleAuth({
  async logout(req, res) {
    await handleLogout(req, res);

Is there a central place where I can clear local storage client side using @auth0/nextjs-auth0?

1 Like

Same question !!! How do I clear local storage is there a config ?