BinaryArtifex
BinaryArtifex
Explore posts from servers
NNuxt
Created by BinaryArtifex on 9/18/2024 in #❓・help
how does nuxt prevent parallel session refresh attempts on a nested route?
ahh right yeah so all external services are called via an in-house sdk. on login, i store the tokens somewhere. if im on products/ page, i call the products endpoint using the access token. i might have a few other components on the products page that call their respective services on page load. the issue comes with closing the browser, coming back later to that same page and the access token has expired. suddenly all services return a 401 and try to refresh the token in parallel. just looking at ways to somehow control the session management such that i avoid a cascade of refresh requests. hope i explained that better
3 replies
NNuxt
Created by BinaryArtifex on 9/18/2024 in #❓・help
how does nuxt prevent parallel session refresh attempts on a nested route?
yeah mate so ive got to use an in-house auth sdk. i get the access and refresh token on login, access tokens have a short life, 30 min i think. its easy enough to attempt a refresh on a 401, but im also managing 10+ services each using that shared access token. my issue now is if i have a service on each nested nuxt route and the token expires, ill endup making n-1 redundant calls. still waiting on remix to release their middleware feature, wondering if theres a nuxt equivilent?
3 replies
NNuxt
Created by luhu on 2/2/2024 in #❓・help
Storybook in Nuxt: Anyone got it running?
its now mid september. senior react dev. been throwin into a greenfields nuxt project, if its one thing i vehemently hate, its frameworks that hide away and manage deps on your behalf, so when problems happen, you gotta wait for someone else to pull the proverbial stick out, like NX, the monorepo manager for example, the amount of work hours ive lost trying to fix things i have no business having to fix in the first place. ive wasted my ENTIRE f*cking work day trying to get storybook going in nuxt....im ok.....
3 replies