apity
apity copied to clipboard
`FetchConfig:use` middleware currently unused
Great project so far, works perfectly for my projects. Only feature it's missing is a middleware provider. I've noticed there's a config to apply middleware, yet it's unused as far as I can tell. Is this feature still planned?
Hi @bddvlpr, thanks for the feedback. Can you describe how exactly do you want to use middlewares with Apity? Or maybe give an example of such middleware. It will help us to provide a better answer or even implement it.
For example, catching when a user is unauthorized for all API calls; every call has a possibility to throw a 401 when the user's token is expired. Using a middleware this could be handled and catched without having to define it for each individual request.