Chromium Code Reviews| Index: pkg/custom_element/lib/polyfill.dart |
| diff --git a/pkg/custom_element/lib/polyfill.dart b/pkg/custom_element/lib/polyfill.dart |
| index 0d041aad06eeec1e057811c9239eaeedaef066f5..94c4e8b6cb33b06ef28022c4d652e0114635ddc7 100644 |
| --- a/pkg/custom_element/lib/polyfill.dart |
| +++ b/pkg/custom_element/lib/polyfill.dart |
| @@ -21,7 +21,9 @@ Future customElementsReady = () { |
| if (_isReady) return new Future.value(); |
| // Not upgraded. Wait for the polyfill to fire the WebComponentsReady event. |
| - return document.body.on['WebComponentsReady'].first; |
| + // Note: we listen on document (not on document.body) to allow this polyfill |
| + // to be loaded in the HEAD element. |
| + return document.on['WebComponentsReady'].first; |
|
Siggi Cherem (dart-lang)
2013/10/23 00:51:33
without this some app fail to run in chrome if the
|
| }(); |
| // Return true if we are using the polyfill and upgrade is complete, or if we |