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

shadowDomCheck does not work in IE11 #2151

Closed
jasperbosch opened this issue Jan 20, 2020 · 3 comments
Closed

shadowDomCheck does not work in IE11 #2151

jasperbosch opened this issue Jan 20, 2020 · 3 comments

Comments

@jasperbosch
Copy link

Stencil version:

 @stencil/core@1.8.5

I'm submitting a:

[x] bug report
[ ] feature request
[ ] support request => Please do not submit support requests here, use one of these channels: https://stencil-worldwide.herokuapp.com/ or https://forum.ionicframework.com/

Current behavior:

IE 11 tries to execute .includes('[native') on undefined wich results in an error.

Expected behavior:

IE 11 should not get an error.

Steps to reproduce:

Try to open an Vue.js application that uses stencil-components in IE11.

Related code:

In src/client/client-windows.ts line 20:

export const supportsShadowDom = (BUILD.shadowDom) ? /*@__PURE__*/(() => (doc.head.attachShadow + '').includes('[native'))() : false;

however the doc.head.attachShadow is undefined in IE11

Other information:

Please revert 84b8e68

@ionitron-bot ionitron-bot bot added the triage label Jan 20, 2020
@adamdbradley
Copy link
Contributor

Can you put together a repo case for this? Tests have been passing on ie11.

@jasperbosch
Copy link
Author

@adamdbradley
Copy link
Contributor

Ok I see, thanks for the repo. In this case the app is not polyfilling includes before its first use. To keep it simple we can use indexOf to help out this scenario. We'll get it fixed in the 1.9.0 prerelease. Thanks

adamdbradley added a commit that referenced this issue Jan 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants