3 ms·
Thanks for the link. I hadn't heard of outline.com before, but seems like a useful service.
by drakenot 8y ago
Thanks for the link. I hadn't heard of outline.com before, but seems like a useful service.
- giodamelio 8y agoIt is pretty nifty. They have a Chrome extension too, but that seems like massive overkill so I threw together a quick bookmarklet [1]. You need a decently new browser to use it. fetch( "https://outlineapi.com/parse_article?source_url=" + encodeURIComponent(window.location) ) .then(res => res.json()) .then(body => { if (body.error) { return alert(`Outline Bookmarklet Error: ${body.error}`); } window.location.href = `https://outline.com/${body.data.short_code}` }) .catch(err => { alert("Outline Bookmarklet Error. See console for details."); console.error(err); }); Or minified to be copied directly into bookmark: javascript:fetch("https://outlineapi.com/parse_article?source_url="+encodeURIComponent(window.location)).then(o=>o.json()).then(o=>{if(o.error)return alert(`Outline Bookmarklet Error: ${o.error}`);window.location.href=`https://outline.com/${o.data.short_code}`}).catch(o=>{alert("Outline Bookmarklet Error. See console for details."),console.error(o)}); [1]: https://gist.github.com/giodamelio/c97f71a12eec5c142f21f757a6ba4d8a https://gist.github.com/giodamelio/c97f71a12eec5c142f21f757a...