graphql-resolver-cache icon indicating copy to clipboard operation
graphql-resolver-cache copied to clipboard

How to invalidate cache?

Open matteodem opened this issue 7 years ago • 2 comments

This pkg looks really useful for a project I'm working on! Is there any way to invalidate cache entries?

Or has that to be done on the cache object itself?

matteodem avatar Mar 16 '18 13:03 matteodem

Hi @matteodem,

Great that you are using this package! You can maybe use this (set the maxAge to 0)? https://github.com/Intellicode/graphql-resolver-cache/blob/master/src/lru-cache.js#L15

Intellicode avatar Mar 16 '18 19:03 Intellicode

Thanks for the hint, I'll try that out and report back

matteodem avatar Mar 17 '18 14:03 matteodem