Skip to content

Instantly share code, notes, and snippets.

@thom4parisot
Created January 24, 2013 22:56
Show Gist options
  • Select an option

  • Save thom4parisot/4629133 to your computer and use it in GitHub Desktop.

Select an option

Save thom4parisot/4629133 to your computer and use it in GitHub Desktop.
Array.prototype.slice.map(document.querySelectorAll('a[href]'), function(el){
return { "href": el.href, "rel": el.rel || null };
});
@karlcow
Copy link
Copy Markdown

karlcow commented Jan 24, 2013

ah. but it's not related to python. It has really nothing to do with it. It can be any languages. I haven't finished the exploration which is about having an API which is independent of URI hard crafting. Most of the API suffers of knowing the URI templating, when in a hypermedia design, the client is discovering the resources through the rel values. :)

There will be more blog posts in the future. I have been busy with a few other things recently ;)

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