I've been trying to find a nice way to deal with authorisation on SPA apps. I'm using Vue but I think the framework is irrelevant to the problem.
It feel like there are lots of options to the problem but none of them feel 'right'. We could pass down props, we could create an auth service on the framework as a plugin that replicates the functionality of the backend server, we could route authorisation requests back to the server - maybe by websocket to avoid tons of http requests. All of these come with downsides.
I'm sure there are issues with this approach that i've overlooked and I'd love to hear what others thoughts are on it? Do you think it's feasible?