Is there a cache library that does this? [closed]

Let’s say there’s a route for fetching projects. Now if we send from the front a request to change a single project (the request return the changed project), it wont update the already cached project.
I’d like a library that somewhat automatically update the get projects cache on a change like this.

I tried looking for a library like this but couldn’t find any, unfortunately.