| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 /** | 5 /** |
| 6 * This library exports all of the commonly used functions and types for | 6 * Custom HTML tags, data binding, and templates for building |
| 7 * building UI's. | 7 * structured, encapsulated, client-side web apps. |
| 8 * | 8 * |
| 9 * See this article for more information: | 9 * Polymer.dart, the next evolution of Web UI, |
| 10 * <http://www.dartlang.org/articles/dart-web-components/>. | 10 * is an in-progress Dart port of the |
| 11 * [Polymer project](http://www.polymer-project.org/). |
| 12 * Polymer.dart compiles to JavaScript and runs across the modern web. |
| 13 * |
| 14 * To use polymer.dart in your application, |
| 15 * first add a |
| 16 * [dependency](http://pub.dartlang.org/doc/dependencies.html) |
| 17 * to the app's pubspec.yaml file. |
| 18 * Instead of using the open-ended `any` version specifier, |
| 19 * we recommend using a range of version numbers, as in this example: |
| 20 * |
| 21 * dependencies: |
| 22 * polymer: '>=0.7.1 <0.8' |
| 23 * |
| 24 * Then import the library into your application: |
| 25 * |
| 26 * import 'package:polymer/polymer.dart'; |
| 27 * |
| 28 * ## Other resources |
| 29 * |
| 30 * * [Polymer.dart homepage](http://www.dartlang.org/polymer-dart/): |
| 31 * Example code, project status, and |
| 32 * information about how to get started using Polymer.dart in your apps. |
| 33 * |
| 34 * * [polymer.dart package](http://pub.dartlang.org/packages/polymer): |
| 35 * More details, such as the current major release number. |
| 36 * |
| 37 * * [Upgrading to Polymer.dart](http://www.dartlang.org/polymer-dart/upgrading-
to-polymer-from-web-ui.html): |
| 38 * Tips for converting your apps from Web UI to Polymer.dart. |
| 11 */ | 39 */ |
| 12 library polymer; | 40 library polymer; |
| 13 | 41 |
| 14 import 'dart:async'; | 42 import 'dart:async'; |
| 15 import 'dart:mirrors'; | 43 import 'dart:mirrors'; |
| 16 | 44 |
| 17 import 'package:mdv/mdv.dart' as mdv; | 45 import 'package:mdv/mdv.dart' as mdv; |
| 18 import 'package:observe/src/microtask.dart'; | 46 import 'package:observe/src/microtask.dart'; |
| 19 import 'package:path/path.dart' as path; | 47 import 'package:path/path.dart' as path; |
| 20 import 'polymer_element.dart' show registerPolymerElement; | 48 import 'polymer_element.dart' show registerPolymerElement; |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 print("warning: methods marked with @initMethod should take no " | 166 print("warning: methods marked with @initMethod should take no " |
| 139 "arguments, ${method.simpleName} expects some."); | 167 "arguments, ${method.simpleName} expects some."); |
| 140 return; | 168 return; |
| 141 } | 169 } |
| 142 obj.invoke(method.simpleName, const []); | 170 obj.invoke(method.simpleName, const []); |
| 143 } | 171 } |
| 144 | 172 |
| 145 class _InitMethodAnnotation { | 173 class _InitMethodAnnotation { |
| 146 const _InitMethodAnnotation(); | 174 const _InitMethodAnnotation(); |
| 147 } | 175 } |
| OLD | NEW |