Created
May 27, 2024 13:05
-
-
Save adokce/5a8778f20b69896581fbb451e427c8e2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Delayed Debugger Script | |
* | |
* This script sets a 2-second delay before triggering the debugger in your browser's developer tools. | |
* It is useful for debugging hover states and other JavaScript-controlled interactions that don't | |
* respond to the browser's built-in hover emulation tools. | |
* | |
* Usage: | |
* 1. Open your browser's developer tools (press F12 or Ctrl+Shift+I). | |
* 2. Navigate to the "Console" tab. | |
* 3. Paste the script into the console and press Enter. | |
* | |
* The script will pause execution and activate the debugger after 3 seconds, | |
* allowing you to inspect and debug the current state of your application. | |
*/ | |
setTimeout(() => { | |
debugger; | |
console.log("Debugger activated"); | |
}, 2000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment