...Setting the domain to 'localhost' will not work on all browsers (eg. Chrome) since some browsers only allow you to set domain cookies for registry-controlled domains, i.e. something ending in .com or so, but not IPs or intranet hostnames like localhost. Configure whether events should be broadcasted on $rootScope for each action. You can also dynamically change storage type by passing the storage type as the last parameter for any of the API calls.