AlokaiA
Alokai3y ago
ALI

VSF2-Nuxt3 app integrated with Magento 2.

I have a vuestorefront 2 application extended with Nuxt and integrated with Magento 2. I was working on SignUp and Login functionality and storing the token from generateCustomerToken method to localStorage. Works perfectly fine but when I try place Guarded Routes and try to access that guarded route directly by typing
url
, it gives me 500 saying 'localStorage is not defined'. It should redirect me to Login page. Below are the screenshots if someone could look into them and suggest a solution.
500-localhost.png
devtools-console.png
index.png
middleware.png
network-headers.png
network-response.png
Was this page helpful?