Better HN
topnewbestaskshowjobs
Log inSign up

vxcwvxcw

2 karma · joined Oct 10, 2019 (7y ago) · 4 submissions

Submissions

comment 7y ago · link · parent

this works at least in chrome console (to get link urls, not emails)

[...($$('a'))].map(e => e.href)

comment 7y ago · link · parent

I came up with:

document.documentElement.innerHTML.split('\n').forEach( (line) => line.includes('mailto:') ? console.log(line) : 0 )

But please push this further (is there a shorter way to say document.documentElement.innerHTML ?)