Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move non-webcomponents script unresolved case to load instead of synchronous #1724

Merged
merged 1 commit into from
Jun 4, 2015

Conversation

dfreedm
Copy link
Member

@dfreedm dfreedm commented Jun 2, 2015

Fixes #1723

@@ -22,7 +22,7 @@
if (window.WebComponents) {
addEventListener('WebComponentsReady', resolve);
} else {
resolve();
addEventListener('load', resolve);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's use document.readyState iff not at least at interactive and then resolve on interactive. load is overly long.

@dfreedm dfreedm force-pushed the fix-scripts-head-unresolved branch from a8c6347 to 2258920 Compare June 3, 2015 00:07
@dfreedm
Copy link
Member Author

dfreedm commented Jun 3, 2015

@sorvell PTAL with the new patch

@sorvell
Copy link
Contributor

sorvell commented Jun 4, 2015

LGTM, thx.

sorvell pushed a commit that referenced this pull request Jun 4, 2015
Move non-webcomponents script unresolved case to `load` instead of synchronous
@sorvell sorvell merged commit b8ffcdd into master Jun 4, 2015
@sorvell sorvell deleted the fix-scripts-head-unresolved branch June 4, 2015 17:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

When not including webcomponentsjs, a script in <head> after imports will break unresolved attribute
3 participants