Skip to content

Instantly share code, notes, and snippets.

@JonathanGawrych
Created June 23, 2025 16:38
Show Gist options
  • Select an option

  • Save JonathanGawrych/6f40180faa1ad08c22b1c65f3ce683b3 to your computer and use it in GitHub Desktop.

Select an option

Save JonathanGawrych/6f40180faa1ad08c22b1c65f3ce683b3 to your computer and use it in GitHub Desktop.
Canvas doesn't have a "unsubscribe from 63 email notifications", so you have to manually click each one. This does it for you
async function wait(ms) { return new Promise((resolve) => setTimeout(resolve, ms));}
for (const svgName of Array.from(document.querySelectorAll('[name=IconCalendarMonth],[name=IconAlerts],[name=IconCalendarDay]'))) {
svgName.parentElement.click();
await wait(100);
document.evaluate('//span[text()="Notifications off"][not(ancestor::*[@aria-hidden="true"])]', document, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue.click()
await wait(100);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment