Skip to content

Instantly share code, notes, and snippets.

@RobertEves92
Last active September 26, 2020 07:56
Show Gist options
  • Save RobertEves92/87d788274c83f1deaf28329b23f37486 to your computer and use it in GitHub Desktop.
Save RobertEves92/87d788274c83f1deaf28329b23f37486 to your computer and use it in GitHub Desktop.
Archive all Facebook messenger chats
(function run() {
let all = document.querySelectorAll('div[aria-label="Conversation actions"]');
if (all.length == 0) return;
let a = all[0];
a.click();
setTimeout(() => {
document.querySelectorAll('a[role=menuitem]').forEach(act => {
if (act.innerText.match(/Hide/)) act.click();
});
run();
}, 250);
})();
@RobertEves92
Copy link
Author

Open https://www.messenger.com/ on chrome
Open developer tools and paste the code into console
Hit Enter key
Wait

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