作者:彦贞法禎3222 | 来源:互联网 | 2023-09-08 19:27
In my popup.html, I have this
在我的popup.html中,我有这个
so then in my popup.js I try to run
所以然后在我的popup.js中我尝试运行
chrome.storage.sync.set({"testkey": 'test'});
I got error of Uncaught TypeError: Cannot read property 'sync' of undefined
我收到了Uncaught TypeError的错误:无法读取undefined的属性'sync'
I'd declare my permission properly :
我正确地申报了我的许可:
"permissions": [
"http://*/*", "https://*/*","storage"
],
"browser_action": {
"default_icon": "icon.png",
"default_popup": "popup.html"
}
1 个解决方案