Skip to content

Instantly share code, notes, and snippets.

@neilio
Last active December 6, 2020 17:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save neilio/c6825f1a120e54586a8d73cf9b5b2a36 to your computer and use it in GitHub Desktop.
Save neilio/c6825f1a120e54586a8d73cf9b5b2a36 to your computer and use it in GitHub Desktop.
Multi configuration
{
"tabs": [
{
"title": "Gmail",
"url": "https://mail.google.com/",
"customJS": [
"file:///Users/neilio/Dropbox/Documents/Software/Multi/gapps.js"
]
},
{
"title": "Slack",
"url": "https://freshbooks.slack.com/"
},
{
"title": "GCal",
"url": "https://calendar.google.com/",
"customJS": [
"file:///Users/neilio/Dropbox/Documents/Software/Multi/gapps.js"
]
},
{
"title": "GDrive",
"url": "https://drive.google.com/drive/u/0/my-drive",
"customJS": [
"file:///Users/neilio/Dropbox/Documents/Software/Multi/gapps.js"
]
},
{
"title": "Jira",
"url": "https://2ndsiteinc.atlassian.net/"
},
{
"title": "Polymail",
"url": "https://app.polymail.io/"
},
{
"title": "Miro",
"url": "https://miro.com/"
}
],
"sideBySide": false,
"alwaysNotify": true,
"openNewWindowsWith": "com.apple.Safari",
"openNewWindowsInBackground": true
}
@neilio
Copy link
Author

neilio commented Dec 6, 2020

Here's the JS I'm linking to:

(() => {
const listener = e => e.stopPropagation();
const query = () => document.querySelectorAll('a[target=_blank]').forEach(a => {
a.removeEventListener('click', listener);
a.addEventListener('click', listener, true);
});
query();
setInterval(query, 400); // wait time between DOM queries, in milliseconds
})();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment