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

Improve importHref() #4348

Closed
wants to merge 9 commits into from

Conversation

gronke
Copy link
Contributor

@gronke gronke commented Feb 28, 2017

  • uses altering test assets to ensure tests do not affect each other
  • ensure importHref always returns a link element
  • ensure onload() and onerror() functions are only called once when the same element was loaded again

Blocked by webcomponents/webcomponentsjs#655 because the load event is invoked twice when a failed import attempt is repeated.

duplicate of #4209 that points against master instead of the branch behind #4200 (refactor-import-href)

Chris Joel and others added 9 commits February 28, 2017 15:59
Previously, importHref would cache failed results. This caused failures
to be cached indefinitely, even when the failure was the result of
conditions that are subject to change over time (such as poor network
connectivity).

This implementation no longer caches failures. Additionally, it relies
on the link tag's presence in the <head> of the document as an
indication that it is loading or has loaded, rather than keeping an
object map of URLs to link tags.
@gronke gronke mentioned this pull request Feb 28, 2017
@dfreedm dfreedm added the 1.x label Apr 4, 2017
@TimvdLippe
Copy link
Contributor

These changes have been incorporated in #4305. Please republish this PR if you find any changes we missed there.

@TimvdLippe TimvdLippe closed this Aug 8, 2017
@gronke
Copy link
Contributor Author

gronke commented Aug 8, 2017

Wow, thanks. I didn't even have to rebase 🎂

@gronke gronke deleted the enhance-refactor-import-href branch August 8, 2017 08:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants