localStorage and sessionStorage done right for AngularJS
ngStorage
is a third-party angular.js
module that provide common wrappers for the SessionStorage
and LocalStorage
browser objects specified with HTML5
APIs. This is a toolbox exposed via some angular services, like $sessionStorage and $localStorage. This module ensure offers coding facilities as a javascript library does, and ensure a good integration in your angular module architecture because you use it as dependencies for your own modules. For example, they can be mocked for unit and e2e testing.
It is an open-source (MIT) software available on github.com: https://github.com/gsklee/ngStorage