Last active
January 18, 2019 18:21
-
-
Save kimagure44/14c948613a26f0fcd345f997f90011a6 to your computer and use it in GitHub Desktop.
binding-app
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link rel="import" href="../../bower_components/polymer/polymer-element.html"> | |
<link rel="import" href="../../bower_components/paper-input/paper-input.html"> | |
<dom-module id="binding-app"> | |
<template> | |
<style> | |
:host { | |
display: block; | |
} | |
</style> | |
<!-- Binding 1 dirección Padre a hijo --> | |
<h2>Tu profesión es.... [[profesion]]</h2> | |
<!-- Binding 2 direciones --> | |
<paper-input label='Profesion 2 Way' value='{{profesion}}'></paper-input> | |
<!-- Binding 1 direción --> | |
<paper-input label='Profesion 1 Way' value='[[profesion]]'></paper-input> | |
</template> | |
<script> | |
/** | |
* @customElement | |
* @polymer | |
*/ | |
class BindingApp extends Polymer.Element { | |
static get is() { return 'binding-app'; } | |
static get properties() { | |
return { | |
profesion: { | |
type: String, | |
value: '' | |
} | |
}; | |
} | |
} | |
window.customElements.define(BindingApp.is, BindingApp); | |
</script> | |
</dom-module> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
hyiuhyu