Skip to content

thomasvaeth/pleaseDontGo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

5 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Please Don't Go ๐Ÿ’”

Please Don't Go is a JavaScript plugin used for changing the title and the favicon of the website when a visitor navigates to another tab in the window.

Installation

Please Don't Go is available on Bower and GitHub.

Bower

bower install pleaseDontGo
<script type="text/javascript" src="path/to/bower_components/pleaseDontGo/dist/pleaseDontGo.min.js"></script>

GitHub

Download the script or the minified version in the dist folder.

<script type="text/javascript" src="path/to/pleaseDontGo.min.js"></script>

Usage

The plugin, which does not depend on jQuery, will look for the link element with rel="icon".

<link rel="icon" type="image/x-icon" href="path/to/favicon.ico">
<script type="text/javascript">
  pleaseDontGo.init({
    newTitle: 'Please Don\'t Go',
    newFavicon: '/assets/images/favicon-dontgo.ico',
    timeout: 2000
  });
</script>

The plugin also allows you to set the new title, the path to the new favicon, and the timeout delay for switching them around.

Changelog

1.0

  • Initial release

Issues

Please submit any issues here.

License

Please Don't Go is licensed under the MIT License.

About

Change the title and the favicon of the website when a visitor navigates to another tab. ๐Ÿ’”

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published