Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(50)

Side by Side Diff: sky/framework/README.md

Issue 694423002: Replace <link rel="import"> with <import> (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 SkyElement 1 SkyElement
2 === 2 ===
3 3
4 SkyElement is the framework for creating...yup...Sky Elements. It take heavy 4 SkyElement is the framework for creating...yup...Sky Elements. It take heavy
5 inspriation from [Polymer](www.polymer-project.org) and isn't very fully 5 inspriation from [Polymer](www.polymer-project.org) and isn't very fully
6 featured...yet 6 featured...yet
7 7
8 Declaring an element 8 Declaring an element
9 -------- 9 --------
10 ```HTML 10 ```HTML
11 <link rel="import" href="../path/to/sky-element.sky" as="SkyElement" /> 11 <import src="../path/to/sky-element.sky" as="SkyElement" />
12 <template> 12 <template>
13 <my-other-element>Hello, {{ place }}</my-other-element> 13 <my-other-element>Hello, {{ place }}</my-other-element>
14 </template> 14 </template>
15 <script> 15 <script>
16 // SkyElement takes a single object as it's only parameter 16 // SkyElement takes a single object as it's only parameter
17 SkyElement({ 17 SkyElement({
18 name: 'my-element', // required. The element's tag-name 18 name: 'my-element', // required. The element's tag-name
19 attached: function() { 19 attached: function() {
20 this.place = 'World'; 20 this.place = 'World';
21 }, // optional 21 }, // optional
(...skipping 21 matching lines...) Expand all
43 Also, because there are so few built-in elements in Sky, the default behavior 43 Also, because there are so few built-in elements in Sky, the default behavior
44 of HTMLElement with bindings is to assign to the property. e.g. 44 of HTMLElement with bindings is to assign to the property. e.g.
45 45
46 ```HTML 46 ```HTML
47 <my-foo bar="{{ bas }}"> 47 <my-foo bar="{{ bas }}">
48 ``` 48 ```
49 49
50 Will not `setAttribute` on the `my-foo`, instead it will assign to the `bar` 50 Will not `setAttribute` on the `my-foo`, instead it will assign to the `bar`
51 property of `my-foo`. There are two exceptions to this: `class` & `style` -- 51 property of `my-foo`. There are two exceptions to this: `class` & `style` --
52 those still`setAttribute`. 52 those still`setAttribute`.
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698