NuxtN
Nuxtβ€’2y agoβ€’
41 replies
stefanpeev

New at nuxt.. and frontend as a whole.

Hi.... Ive been beating my head with nuxt for 2 weeks, I find the documentation very hard to understand.
I am trying to connect my backend with my frontend.I am using sidebase and authjs.. So far ive managed to make an authorized login, but im having a lot of trouble with fetching data with authentication and setting a useState global variable.Basically i want to login, get a jwt token and set a part of the user's data -"usertype" to a global variable because that one changes my layouts and what can the user see on a page. And I want to request data that required authentication.. send my jwt token from my cookies to the backend, fetch the data and show it on my nuxt frontend.
Also I am facing troubles with a vuetify button whichs @click doesnt work..i tried .native and many other ways still not working.
Was this page helpful?