Tamper Web Pages Using Tampermonkey
Hello. Before diving into this article, first, we need to know few things.
1. What is a Userscript?
2. Why we need a Userscript?
3. How to add Userscript to a web page?
4. What is a Userscript Manager?
A userscript manager is a type of browser extension that provides a user interface to manage userscripts.
One of the popular userscripts managers is Tampermonkey. This article will add a Toggle password visibility feature using Tampermonkey which adds a checkbox for all the password inputs on a page. The checkbox can be used to show and hide the password.
Tampermonkey extension is available for almost all the browsers like Chrome, Firefox, Edge, Safari, etc. You can download the chrome extension here.
Userscript to Add Show Password Checkbox
The userscript can be downloaded from the below gist.
Run Userscript in Tampermonkey
- Open your browser and click the Tampermonkey icon and click Create a new script
2. It will redirect to a new page. Copy the script on the page and make sure @match is set to https://*/* so that the script runs for all sites. Click ctrl + s to save it.
3. Now open any web page that has a password box. Here I am opening Github and Geeks for Geeks.
Tampermonkey comes in handy where we need to modify the content of any web page to add custom functionality. We can add any functionalities from modifying HTML DOM to making Ajax calls.
Thank you 🤘
To know more about me, visit ganeshkumarm.me