Skip to content

Instantly share code, notes, and snippets.

@Glavin001
Created May 9, 2018 20:04
Show Gist options
  • Save Glavin001/eb11a6358986fc4789ef46533d8bd56f to your computer and use it in GitHub Desktop.
Save Glavin001/eb11a6358986fc4789ef46533d8bd56f to your computer and use it in GitHub Desktop.
Backup Slack Emojis
  1. Run the RunInBrowser.js script by copying and pasting into the Developer Tools' Console.
JSON.stringify(Array.from(document.querySelectorAll("#custom_emoji tr.emoji_row")).map(row => {
const tds = row.getElementsByTagName('td');
const [ imageEl, nameEl, typeEl, addedByEl ] = tds;
const image = imageEl.getElementsByTagName('span')[0].dataset.original;
const name = nameEl.innerHTML.trim().slice(1,-1);
return { image, name };
}));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment