Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Commit

Permalink
listen for HTMLImportsLoaded only if HTMLImports.ready is false
Browse files Browse the repository at this point in the history
  • Loading branch information
sorvell committed Jan 14, 2014
1 parent 75798bf commit 51c8369
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/boot.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ if (document.readyState === 'complete' || scope.flags.eager) {
// When loading at other readyStates, wait for the appropriate DOM event to
// bootstrap.
} else {
var loadEvent = window.HTMLImports ? 'HTMLImportsLoaded' : 'DOMContentLoaded';
var loadEvent = window.HTMLImports && !HTMLImports.ready ?
'HTMLImportsLoaded' : 'DOMContentLoaded';
window.addEventListener(loadEvent, bootstrap);
}

Expand Down

0 comments on commit 51c8369

Please sign in to comment.