File tree 3 files changed +74
-1
lines changed
3 files changed +74
-1
lines changed Original file line number Diff line number Diff line change 69
69
// have resolved
70
70
var self = this ;
71
71
Polymer . RenderStatus . whenReady ( function ( ) {
72
- self . _markImportsReady ( ) ;
72
+ if ( document . readyState == 'loading' ) {
73
+ document . addEventListener ( 'DOMContentLoaded' , function ( ) {
74
+ self . _markImportsReady ( ) ;
75
+ } ) ;
76
+ } else {
77
+ self . _markImportsReady ( ) ;
78
+ }
73
79
} ) ;
74
80
} ,
75
81
Original file line number Diff line number Diff line change 69
69
'unit/dom-if.html' ,
70
70
'unit/dom-template.html' ,
71
71
'unit/dom-bind.html' ,
72
+ 'unit/dom-bind-yield.html' ,
72
73
'unit/script-after-import-in-head.html' ,
73
74
'unit/globals.html'
74
75
] ;
Original file line number Diff line number Diff line change
1
+ <!doctype html>
2
+ <!--
3
+ @license
4
+ Copyright (c) 2014 The Polymer Project Authors. All rights reserved.
5
+ This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
6
+ The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
7
+ The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
8
+ Code distributed by Google as part of the polymer project is also
9
+ subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
10
+ -->
11
+ < html >
12
+ < head >
13
+ < meta charset ="utf-8 ">
14
+ < script src ="../../../web-component-tester/browser.js "> </ script >
15
+ </ head >
16
+ < body >
17
+
18
+ < link rel ="import " href ="../../polymer.html ">
19
+
20
+ < script >
21
+ if ( window . Polymer ) {
22
+ Polymer ( {
23
+ is : 'x-fire' ,
24
+ ready : function ( ) {
25
+ this . fire ( 'fired' ) ;
26
+ }
27
+ } )
28
+ }
29
+ </ script >
30
+
31
+ < template is ="dom-bind " id ="domBind ">
32
+ < x-fire on-fired ="fired "> </ x-fire >
33
+ </ template >
34
+
35
+ < script >
36
+ if ( window . Polymer ) {
37
+ var now = Date . now ( ) + 1000 ;
38
+ while ( Date . now ( ) < now ) {
39
+ Math . random ( ) ;
40
+ }
41
+ }
42
+ </ script >
43
+
44
+ < script >
45
+ window . domBind . fired = function ( ) {
46
+ this . didFire = true ;
47
+ }
48
+ </ script >
49
+
50
+ < script >
51
+
52
+ if ( window . Polymer ) {
53
+
54
+ suite ( 'bind stamps after page fully loads (despite yielding)' , function ( ) {
55
+
56
+ test ( 'event handled' , function ( ) {
57
+ assert . isTrue ( window . domBind . didFire ) ;
58
+ } ) ;
59
+
60
+ } ) ;
61
+
62
+ }
63
+
64
+ </ script >
65
+ </ body >
66
+ </ html >
You can’t perform that action at this time.
0 commit comments