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

Chrome no longer supports HTML imports as of version 80 #3419

Closed
dark-panda opened this issue Feb 6, 2020 · 6 comments · Fixed by #3556
Closed

Chrome no longer supports HTML imports as of version 80 #3419

dark-panda opened this issue Feb 6, 2020 · 6 comments · Fixed by #3556

Comments

@dark-panda
Copy link

It seems that having removed HTML imports in Chrome 80 breaks things involving fetching HTML files via <link href="%s.html" rel="import"> style imports. It appears that the files are still fetched, but they are no longer executed, leaving karma to show 0 tests being run in my setup. Using Chrome 79 and below works fine.

@dark-panda
Copy link
Author

Until a fix can be applied, you can add a custom launcher that adds the --enable-blink-features=HTMLImports flag to allow HTML imports again.

@vorillaz
Copy link

For anyone stuck with this one, we have managed to run our specs using a Chromium binary.

  1. Download Chromium 79 or older for your platform from https://commondatastorage.googleapis.com/chromium-browser-snapshots/index.html
  2. Unzip the folder in a local directory e.g. /Users/theo/Downloads/chrome-mac/
  3. Set CHROME_BIN=/Users/theo/Downloads/chrome-mac/Chromium.app/Contents/MacOS/Chromium yarn test

@devoto13
Copy link
Collaborator

What do you guys expect Karma to do about it?

This feature has been removed from the only browser where it was supported and HTML Imports feature is obsolete. So the best we can do is to add a notice to the documentation that it does not work in the latest browsers.

@devoto13
Copy link
Collaborator

devoto13 commented May 23, 2020

Depending on your use case you may try setting type to dom to inline the imported files, setting the flag or adding a polyfill for HTLM imports.

devoto13 added a commit to devoto13/karma that referenced this issue May 23, 2020
Also added similar note for `dart` include type.

Fixes karma-runner#3419
devoto13 added a commit to devoto13/karma that referenced this issue Sep 2, 2020
Also added similar note for `dart` include type.

Fixes karma-runner#3419
johnjbarton pushed a commit that referenced this issue Sep 8, 2020
Also added similar note for `dart` include type.

Fixes #3419
@karmarunnerbot
Copy link
Member

🎉 This issue has been resolved in version 5.2.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

anthony-redFox pushed a commit to anthony-redFox/karma that referenced this issue May 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants