jamesplease/react-request

add the ability to "set" the cached value

Aperta

#176 aperta il 25 mag 2018

 (9 commenti) (0 reazioni) (0 assegnatari)JavaScript (21 fork)github user discovery
enhancementhelp wanted

Metriche repository

Star
 (358 stelle)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

It would be nice if there were an extra render prop that allowed you to "set" the cached value to a new value, in the case of updating the cache for a mutation. This way you could nest a patch inside a get and use the update method to update the cache without having to re-request. (Same goes for post/delete as well.)

Guida contributor