Bookmarklets are small peice of JavaScript code that is stored as bookmarks in browser. Bookmarklets help in automating repetitive task, access hidden information from page.
Simple bookmarklets look like this
javascript:alert(location.href)
Just copy the above code and save it as bookmark,
Once bookmark is saved you can click on it run on any webpage.
Bookmarklets have javascript: prefix,
Wihtout javascript: prefix any JavaScript code saved as bookmark will not run in browser.
Pros of using Bookmarklets #
- No need to install any Chrome extension for simple things,
- No code is auto inserted into any page unless you decide,
- You can write your own helpfull bookmarklets on your own, (like quickly adding ling to feedly, pocket or sending link through pushbullet)
Cons of using Bookmarklets #
- Bookmarklets do not run automatically or trigger on schedule,
- List of website that offer Bookmarklets are limited
If you want to create your bookmarklet then here is full post about How to create your own Bookmarklet