$ionicHistory.clearCache() doesn't work


Hi guys,
When i used $ionicHistory.clearCache(); with clearHistory, app is getting stuck and can’t do any thing. Is there any work around to clear cache with out using cache-view=“false”.
what i need is, cache the pages and then remove that cache when i am logging out.



Hi there, maybe with this:




but it should be placed in side .config, i want something that can run inside controller


After 1.1.0 clearCache now returns a promise so you should do the following

      //do something  


I update my ionic version in project now the above function works. Thank you @sindri