Reputation: 1811
As per the storage api http://developer.chrome.com/extensions/storage.html, I am setting the data like this:
chrome.storage.sync.set({'key': 'value'}, function(){});
Getting value like this:
chrome storage.sync.get(["key1", "key2"], function(res){
});
Locally I tried like this:
Uploaded chrome app to webstore, logged into my gmail, installed app from webstore, open app,
added some data to the app(I mean used app). called the function that uses sync.set. Then cleared localstorage, then called the function that uses sync.get and it worked. But, I tried logging into another system with the same email and installed app and called the function that uses 'sync.get'. This time it returned 'empty' object. Did I miss anything ?
Will provide more information if necessary.
Upvotes: 0
Views: 502
Reputation: 19835
For this case, the answer is that you need to be logged into chrome in both computers, not just the site.
Upvotes: 1