mikemaccana / outdated-browser-rework

Detects outdated browsers and advises users to upgrade to a new version. Handles mobile devices!
MIT License
226 stars 63 forks source link

Callback option for when upgrade notice is triggered #86

Open jadbox opened 5 years ago

jadbox commented 5 years ago

I'd like to log to ganalytics when this lib detects the browser is below the configured threshold. I can best log the event if there was a callback option in the outdatedBrowserRework constructor configuration. I'd recommend using the property name onOutdated.

mikemaccana commented 5 years ago

Sure! Send a PR.

Note the code for this project has to be ES3.

jadbox commented 5 years ago

Seems like this PR is related https://github.com/mikemaccana/outdated-browser-rework/pull/32