Activate ionic cache

1

I have a problem with the cache in an app made with Ionic.

Supposedly active the cache in the "config" of the module in the following way

app.config(function($ionicConfigProvider) {
    $ionicConfigProvider.tabs.position('bottom');
    $ionicConfigProvider.views.maxCache(5); // <-- aquí
});

Still, the cache is not activated.

What can I be doing wrong?

    
asked by xfrr 15.01.2017 в 01:25
source

1 answer

1

Try adding cache:true to the file where you manage your routes.

$stateProvider.state('estado', {
   url: '/name',
   cache: true,
   controller:'EstadoCtrl',
   templateUrl:'templates/estado.html'
})
    
answered by 15.01.2017 / 02:14
source