Skip to content

Instantly share code, notes, and snippets.

@LoveAndHappiness
Last active March 17, 2016 06:56
Show Gist options
  • Select an option

  • Save LoveAndHappiness/89ff51c6f2e785189fdd to your computer and use it in GitHub Desktop.

Select an option

Save LoveAndHappiness/89ff51c6f2e785189fdd to your computer and use it in GitHub Desktop.
Google News Polymer Api
// byutv-jsonp for a subsitute to cross origin resources information (cors)
<byutv-jsonp
auto
url="https://ajax.googleapis.com/ajax/services/search/news"
params='{"v":"1.0","rsz":"8","pz":"1","cf":"all","ned":"in","hl":"en","topic":"tc"}'
last-response="{{newsResponse}}"
debounce-duration="300"></byutv-jsonp>
<paper-tabs selected="{{selected}}">
<paper-tab>Google News</paper-tab>
</paper-tabs>
<iron-pages selected="{{selected}}">
<section>
<h1>Google News Response</h1>
<template is="dom-repeat" items="{{newsResponse.responseData.results}}">
<paper-material elevation="1">
<h4>[[item.title]]</h4>
<p>[[item.content]]</p>
</paper-material>
</template>
</section>
</iron-pages>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment