JSFiddle - React, Tailwind, and code Playground

by vjeux

HTML

<script src="http://www.polymer-project.org/polymer/polymer.min.js"></script>
<tk-node-finding></tk-node-finding>

<element name="tk-node-finding" attribute="owner color">
  <template>
    <p>
    This is a <strong>{{owner}}</strong>'s tk-element.
    He likes the color <b style="color: {{color}}">{{color}}</b>.
    </p>
    <button on-click="setFocus">Set focus to text input</button>
    <input id="nameInput" value="{{owner}}" placeholder="Your name here...">
  </template>
  <script>
    Polymer.register(this, {
      color: "red",
      owner: "Daniel",
      setFocus: function() {
        this.$.nameInput.focus();
      }
    });
  </script>
</element>