| OLD | NEW |
| (Empty) |
| 1 <!doctype html> | |
| 2 <html> | |
| 3 <head> | |
| 4 | |
| 5 <title>polymer-localstorage</title> | |
| 6 | |
| 7 <script src="../platform/platform.js"></script> | |
| 8 | |
| 9 <link rel="import" href="core-localstorage.html"> | |
| 10 | |
| 11 </head> | |
| 12 <body> | |
| 13 | |
| 14 <x-test1></x-test1> | |
| 15 | |
| 16 <polymer-element name="x-test1" noscript> | |
| 17 <template> | |
| 18 string entered below will be stored in localStorage and automatically retr
ived from localStorage when the page is reloaded<br> | |
| 19 <input value="{{value}}"> | |
| 20 <core-localstorage name="polymer-localstorage-x-test1" value="{{value}}"><
/core-localstorage> | |
| 21 </template> | |
| 22 </polymer-element> | |
| 23 | |
| 24 <br><br> | |
| 25 | |
| 26 <x-test2></x-test2> | |
| 27 | |
| 28 <polymer-element name="x-test2"> | |
| 29 <template> | |
| 30 <input type="checkbox" checked="{{mode}}"> | |
| 31 <core-localstorage name="polymer-localstorage-x-test2" value="{{mode}}"></
core-localstorage> | |
| 32 </template> | |
| 33 <script> | |
| 34 Polymer('x-test2', { | |
| 35 mode: false | |
| 36 }); | |
| 37 </script> | |
| 38 </polymer-element> | |
| 39 | |
| 40 </body> | |
| 41 </html> | |
| OLD | NEW |