axios-cache-adapter icon indicating copy to clipboard operation
axios-cache-adapter copied to clipboard

Custom Invalidate Function - Type Error on removeItem, uuid

Open KumarSumitD opened this issue 2 years ago • 1 comments

Hi, As per the Readme https://github.com/RasCarlito/axios-cache-adapter/blob/master/README.md?plain=1#L366. Custom invalidate function can be defined and the cache can be busted by - await config.store.removeItem(config.uuid)

There are two types issue -

  • Property 'removeItem' does not exist on type 'object'.
  • Property 'uuid' does not exist on type 'IAxiosCacheAdapterOptions'.

We can try making as unknow as any and as any, but this will error prone. So if we correct types for both.

KumarSumitD avatar Aug 17 '22 17:08 KumarSumitD

Hey, axios-cache-adapter unmaintained, axios-cache-interceptors offers this same feature for less problems :)

I'm the maintainer of https://axios-cache-interceptor.js.org, you should check it out...

arthurfiorette avatar Feb 19 '23 22:02 arthurfiorette