chrome extensions & debug
chrome extensions & debug
debug background.js

debug popup.js

debug content_script.js


chrome.storage
chrome.storage.sync.getbug

// array OK
chrome.storage.sync.get([
"jira_str",
"jira_obj"
], function(items) {
console.log(`chrome.storage.sync.get OK!`);
console.log(`get items =`, JSON.stringify(items, null, 4));
});
// object Error
chrome.storage.sync.get({
jira_str,
jira_obj,
}, function(items) {
console.log(`chrome.storage.sync.get OK!`);
console.log(`get items =`, JSON.stringify(items, null, 4));
});
// chrome.storage.sync.get({
// "jira_str",
// "jira_obj",
// }, function(items) {
// console.log(`chrome.storage.sync.get OK!`);
// console.log(`get items =`, JSON.stringify(items, null, 4));
// });
API
https://developer.chrome.com/extensions/storage
https://developer.chrome.com/extensions/storage#using-sync
To store user data for your extension, you can use either
storage.sync, orstorage.local
// storage.sync
chrome.storage.sync.set({key: value}, function() {
console.log('Value is set to ' + value);
});
chrome.storage.sync.get(['key'], function(result) {
console.log('Value currently is ' + result.key);
});
// storage.local:
chrome.storage.local.set({key: value}, function() {
console.log('Value is set to ' + value);
});
chrome.storage.local.get(['key'], function(result) {
console.log('Value currently is ' + result.key);
});
https://stackoverflow.com/questions/14531102/saving-and-retrieving-from-chrome-storage-sync
https://stackoverflow.com/questions/22636771/chrome-storage-sync-vs-chrome-storage-local
https://bugs.chromium.org/p/chromium/issues/detail?id=161771
localStorage API
https://developer.mozilla.org/en/DOM/Storage#localStorage
zip
bash shell zip
# admin pwd
$ sudo apt install zip
$ zip -r chrome-jira.2018.12.18.zip chrome-jira/*

https://www.cnblogs.com/xgqfrms/p/9714161.html
official api docs
https://developer.chrome.com/extensions
https://developer.chrome.com/extensions/windows
https://developer.chrome.com/extensions/extension
https://developer.chrome.com/extensions/commands
https://developer.chrome.com/extensions/browserAction
https://developer.chrome.com/extensions/pageAction
https://developer.chrome.com/extensions/runtime
https://developer.chrome.com/extensions/runtime#property-lastError
https://developer.chrome.com/extensions/tabs
https://developer.chrome.com/extensions/system_storage
https://developer.chrome.com/extensions/system_memory
https://developer.chrome.com/extensions/system_cpu
https://developer.chrome.com/extensions/platformKeys
https://developer.chrome.com/extensions/omnibox
chrome extensions & debug的更多相关文章
- Jira & SVN & Chrome extensions
Jira & SVN & Chrome extensions Plugins SVN & Jira Plugins ok selector bug document.query ...
- 如何在Chrome下Debug Mocha的测试
简介 经过前两篇文章的介绍,相信读者对Mocha应该有一定的认知了,本文重点讲述如何在Chrome下Debug Mocha Test, 方便你在测试fail的时候troubleshooting. 关键 ...
- Best Chrome Extensions
Best Chrome Extensions chrome://extensions/ # ghelper chrome-extension://cieikaeocafmceoapfogpffaalk ...
- Chrome Extensions API & options
Chrome Extensions API options https://developer.chrome.com/extensions https://developer.chrome.com/e ...
- Do Chrome extensions access iframes? chrome扩展插件访问所有iframes
32down voteaccepted Yes, a Chrome Extension "content script" can run in all iframes (that ...
- chrome浏览器debug
Chrome浏览器审查元素 1.Elements标签页 Elements标签页的左侧就是对页面HTML结构的查看与编辑,你可以直接在某个元素上双击修改元素的属性. 1.Edit as HTML直接对元 ...
- chrome extensions notifications
developer.chrome.comhttps://developer.chrome.com/extensions/notifications notification | MDNhttps:// ...
- chrome dev debug network 的timeline说明
在使用chrome的时候F12的开发者工具中有个network,其中对每个请求有个timeline的说明,当鼠标放上去会有下面的显示: 这里面的几个指标在说明在chrome使用文档有说明: 下面我用人 ...
- chrome extensions
chrome web store AppsGamesExtensionsThemes CATEGORIES All FEATURESClear Runs Offline By ...
随机推荐
- HCA数据下载
HCA data downloads HCA data downloads PeRl` 还记得去年看的时候还是什么都没有,今年已经有数据可以下载了.
- 一个java新手配置IIS服务器的血泪史
接到一个二次开发项目,听说是asp页面,带着不要怂的态度于是接下了. 好嘛按照步骤来 1.了解需求:一个公司内部积分排名类型项目,已经被多次开发,我所需要的就是新增两个页面,一个是分店赛一个是分部赛. ...
- sql 删除表字段中所有的空格
源地址:http://bbs.csdn.net/topics/30322040 Sample表中有一个Name字段,目前当中有很多记录含有空格,如:“ 张 学 友 ”,如何用SQL语句将这些空格删掉, ...
- 北京Uber优步司机奖励政策(1月30日)
滴快车单单2.5倍,注册地址:http://www.udache.com/ 如何注册Uber司机(全国版最新最详细注册流程)/月入2万/不用抢单:http://www.cnblogs.com/mfry ...
- Farpoint使用一点小总结
Farpoint表格编辑的功能是非常强大的,记录下自己常用到的地方. 使用的版本:FarPoint.Win.Spread.5.0 1.Farpoint 设置为不可编辑状态 this.FPProxyIt ...
- DXF结构查看小工具,DXF表格导出工具,CAD文档查看
用C#写了个查看DXF结构的工具,另做了个DXF表格(普通直线画的)导出为CSV表格工具发出来方便各位机械工程师,上几个图: 程序下载: 程序,需要.NET 4.0执行环境 https://pan.b ...
- Consul初体验
Preface Today I'm gonna implement a consul in my environment to discover service of MySQL da ...
- 「日常训练」Balancing Act(POJ-1655)
题意与分析 树的重心板子题. 值得考虑的是,重心究竟有哪些优秀的性质? 这里是一些网上能看到的性质: (判定性质)找到一个点,其所有的子树中最大的子树节点数最少(子树可以"倒着看" ...
- VMware 15.0下载及安装教程
虚拟机 VMware WorkStation Pro15 下载及安装详细解 9虚拟机 VMware WorkStation Pro15 下载及安装详细解. 虚拟机官方网站: https://www.v ...
- Python入门编程中的变量、字符串以及数据类型
//2018.10.10 字符串与变量 1. 在输出语句中如果需要出现单引号或者双引号,可以使用转义符号\,它可以将其中的歧义错误解释化解,使得输出正常: 2. 对于python的任何变量都需要进行赋 ...