I store some data in the localStorage
what I want in my angularjs app is that when the data in the localStorage changed, the app rerender the app, how can I do this?
Incidentally, I've created yet another localStorage module for AngularJS which is called ngStorage:
https://github.com/gsklee/ngStorage
Usage is ultra simple:
JavaScript
$scope.$storage = $localStorage.$default({
x: 42
});
HTML
And every change is automagically sync'd - even changes happening in other browser tabs!
Check out the GitHub project page for more demos and examples ;)