| Index: third_party/polymer/v0_8/components-chromium/polymer/src/lib/template/x-autobind.html
|
| diff --git a/third_party/polymer/v0_8/components-chromium/polymer/src/lib/template/x-autobind.html b/third_party/polymer/v0_8/components-chromium/polymer/src/lib/template/x-autobind.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..093fafd487567dbc31c2a84958399d628c022af7
|
| --- /dev/null
|
| +++ b/third_party/polymer/v0_8/components-chromium/polymer/src/lib/template/x-autobind.html
|
| @@ -0,0 +1,49 @@
|
| +<!--
|
| +@license
|
| +Copyright (c) 2014 The Polymer Project Authors. All rights reserved.
|
| +This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
|
| +The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
|
| +The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
|
| +Code distributed by Google as part of the polymer project is also
|
| +subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
|
| +--><!--
|
| +
|
| +**THIS ELEMENT IS EXPERIMENTAL. API AND NAME SUBJECT TO CHANGE.**
|
| +
|
| +Polymer's binding features are only available within templates that are managed
|
| +by Polymer. As such, these features are available in templates used to define
|
| +Polymer elements, for example, but not for elements placed directly in the main
|
| +document.
|
| +
|
| +In order to use Polymer bindings without defining a new custom element, elements
|
| +utilizing bindings may be wrapped with the `x-autobind` template extension.
|
| +This template will immediately stamp itself into the main document and bind
|
| +elements to the template itself as the binding scope.
|
| +
|
| +```html
|
| +<!doctype html>
|
| +<html>
|
| +<head>
|
| + <meta charset="utf-8">
|
| + <script src="components/webcomponentsjs/webcomponents-lite.js"></script>
|
| + <link rel="import" href="components/polymer/polymer.html">
|
| + <link rel="import" href="components/core-ajax/core-ajax.html">
|
| +
|
| +</head>
|
| +<body>
|
| +
|
| + <template is="x-autobind">
|
| +
|
| + <core-ajax url="http://..." lastresponse="{{data}}"></core-ajax>
|
| +
|
| + <template is="x-repeat" items="{{data}}">
|
| + <div><span>{{item.first}}</span> <span>{{item.last}}</span></div>
|
| + </template>
|
| +
|
| + </template>
|
| +
|
| +</body>
|
| +</html>
|
| +```
|
| +
|
| +--><html><head></head><body><script src="x-autobind-extracted.js"></script></body></html>
|
|
|