Skip to content

Instantly share code, notes, and snippets.

  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save fokusferit/3924430fa9875b8d39c6635afc0fe4ed to your computer and use it in GitHub Desktop.
<link rel="import" href="../../bower_components/polymer/polymer.html">
<link rel="import" href="../../bower_components/iron-ajax/iron-ajax.html">
<link rel="import" href="../../bower_components/paper-input/paper-input.html">
<dom-module id="ajax-multiple">
<section id="content">
<paper-input id="post" label="Post" value="{{title}}" on-blur="resolve">
<iron-ajax auto url="{{resolveUrl}}" handle-as="json" on-response="onResponse" id="xhr"></iron-ajax>
'use strict';
const url = "";
is: 'ajax-multiple',
title: {
type: String
resolveUrl: {
type: String
resolve: function(event) {
if(^[0-9]+$/)) {
this.set('resolveUrl', url +;
onResponse: function(response){
this.set('title', response.detail.response.title);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment