I'm implementing a notification feature on my app using the ionic framework. the way it works is i make a get request to a rest api that returns an array of notifications. but this seem too much because i have to make a request to the same list everytime, So i was thinking of storing the first request in a local variable (using ngStorage) and just pull up the new items in next requests.. Is this solution possible? if so can you give example on how to go about this
/* Example 1 first request of Json, i'll store the list in a $localStorage variable*/
[{id:1, notification:'notif A'},
{id:2, notification:'notif B'}]
/* For the second request, I only want to push get 'id:3' to my $localStorage how is this possible*/
[{id:1, notification:'notif A'},
{id:2, notification:'notif B'},
{id:3, notification:'notif C'}]