Created
March 9, 2019 08:48
-
-
Save no1xsyzy/0de2e58abedd8f57ec47ab276ad7ed64 to your computer and use it in GitHub Desktop.
This file contains 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
((m=>`${m.replace(/([?&])name=[^&]+/, "$1name=orig")} --out=twitter${(x=>x[x.length-1])(window.location.pathname.split("/"))}.${/[&?]format=([^&]+)&/.exec(m)[1]}`)(document.querySelector(`div[data-testid="primaryColumn"] img[src^="https://pbs.twimg.com/media"]`).src)) | |
((ms,f)=>ms.map(f(ms.length>1)).join("\n"))(Array.from(document.querySelectorAll(`div[data-testid="primaryColumn"] img[src^="https://pbs.twimg.com/media"]`)).map(x=>x.src), (l=>{var c=0;return m=>`${m.replace(/([?&])name=[^&]+/, "$1name=orig")} --out=twitter${(x=>x[x.length-1])(window.location.pathname.split("/"))}${l?"-"+("0"+(++c)).slice(-2,100):""}.${/[&?]format=([^&]+)&/.exec(m)[1]}`})) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment