Angular cache *2.x.x* is really
awesome: http://jmdobry.github.io/angular-cache/
*~The 3.x.x is completely different and there is too much thing there... I
think they made wrong decision about 3.x.x~*
With angular-cache, you can cache things on client, and configure to when
it expires, it automatically request new data again:
$angularCacheFactory('profileCache', {
maxAge: 3600000,
deleteOnExpire: 'aggressive',
onExpire: function (key, value) {
$http.get(key).success(function (data) {
profileCache.put(key, data);
});
}
});
On Friday, November 14, 2014 4:10:01 AM UTC-2, Kevin Huang wrote:
>
> New to here. Sorry if I post question at wrong channel.
>
> We are using angularjs+pyramid. Our web needs to show a table read from an
> endpoint which is seldom updated. Is there anyway to cache the data on
> client side to reduce the communication to back-end? If the data is cached,
> what is the best way to get the updated data (like periodically polling)?
> Any suggestion is appreciated. Thanks a lot!
>
--
You received this message because you are subscribed to the Google Groups
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.