问题描述
在chrome应用程序上工作,该应用程序基本上是一个笔记记录应用程序,我可以在其中添加ul,该ul作为待办事项列表独立运行。我对此有一个很大的问题,可能是最重要的部分。保存所做的实际更改。我尝试了以下操作:
$('.gallery-filters .filter-item').on('click',function () {
var activegallery = ($(this).data('filter')); //get the current filter
$(".photoswipe-gallery .gallery-item a").each(function () {
$(this).removeClass('photoswipe'); //remove all photoswipe classes
});
$(".photoswipe-gallery .gallery-item" + activegallery +" a").each(function () {
$(this).addClass('photoswipe'); //add photoswipe class only for active images
});
});
我也尝试chrome.storage.sync无济于事。在更改html和事件侦听器的每个函数上,我都有“ chrome.storage.local.set({'full':entire})”。
在onbeforeunload控制台日志上,我仅获得与原始文件中完全相同的html,而不是退出应用程序之前的html。
这里有完整的github链接。 先感谢您!这样做不仅是为了学习,而且因为这对我作为学生来说非常有用。
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)