Let's say I'm making a request for /products.json
which returns a JSON array with X number of products. Each is available at /product/[id].json
. Is it possible to make siesta cache that information instead of making a request for each product? Or do I have to cache my models separate from their resources?
cache multiple resources from a single request
169 views Asked by Mark Lilback At
1
There’s a short discussion of this here:
https://github.com/bustoutsolutions/siesta/issues/156
As Siesta currently exists, each URL is a separate resource with a separate cached state. However, you can manually propagate changes from an index/list/search resource to the corresponding resources for its individual results:
That that Github issue discussion for more background.