zlog

(!!!!以前的好用的, 现在不行了~)

做chrome扩展桌面通知, 可能不想让浏览器自动关闭某个重要的桌面通知.
那就不要使用 chrome.notifications.create

可以用 Web Notifications
用法:

var notification = new Notification(
  "New Email Received", {icon: "mail.png", tag: {msg} });

notification.onshow = function() {
  setTimeout(function(){
   notification.close()}, 15000)
};

参考:
http://www.w3.org/TR/notifications/
https://developer.chrome.com/extensions/api_index

分类:

技术点:

相关文章:

  • 2021-05-01
  • 2021-06-17
  • 2021-10-14
  • 2021-12-04
  • 2021-07-29
猜你喜欢
  • 2021-12-31
  • 2021-09-30
  • 2022-12-23
  • 2021-10-23
  • 2021-12-04
  • 2021-12-04
相关资源
相似解决方案