barbushin / javascript-errors-notifier

Google Chrome and Firefox extension that notifies about JavaScritp errors by icon in address bar & popups
MIT License
205 stars 62 forks source link

Support chrome.notifications #77

Closed himdel closed 6 years ago

himdel commented 6 years ago

This adds a basic chrome.notifications support:

foo


This is probably still missing code to destroy the notifications. Also, it looks like it behaves differently (ie not at all) for console.error, a missing hook somewhere?

If there's any interest in this, we could also look into click actions, and respecting more of the options which affect only the HTML popup now.

barbushin commented 6 years ago

Sorry, but I'm not sure I understand what is the benefit of showing chrome standard notifications comparing to icon+HTML popup. Chrome popups can display only limited length of text + it will be very annoying if there will be many errors --> many popups.

Some previous version of JEN already has Chrome popups, but then I've removed it.

Anyway, thanks for you effort!

himdel commented 6 years ago

No problem :).

Myself, I don't like the icon because it obscures part of the page and doesn't even work for me (#54), but more importantly, I want to see the error immediately, whereas the icon just tells me there's been one, and I want it to disappear if I'm doing other stuff ... which is a perfect use case for notifications :).

(I tried to use JNote for a while, but that is missing localhost filter/whitelisting. and is not opensource.)

I'll probably fork the extension then, remove the icon stuff I wasn't using, clean up the global/local setting distinction which confused me, and just make it a "show chrome notification for whatever errors appear in the console (with some filtering)" thing :).

barbushin commented 6 years ago

There is a global option that enables popup to be displayed automatically, and you can hide it clicking on Close icon.

image

I really don't understand what is the problem. Sorry.