ionic-team / stencil

A toolchain for building scalable, enterprise-ready component systems on top of TypeScript and Web Component standards. Stencil components can be distributed natively to React, Angular, Vue, and traditional web developers from a single, framework-agnostic codebase.
https://stenciljs.com
Other
12.41k stars 777 forks source link

Stencil flags aren't working to build Stencil apps/components for Internet Explorer (IE) #2894

Closed davidprae closed 2 years ago

davidprae commented 3 years ago

Stencil version:

@stencil/core@2.5.2

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: Viewing Stencil App in Internet Explorer always results in "This Stencil app is disabled for this browser". Running the build with --prod and/or --es5 produces the same result.

Expected behavior: I can view the Stencil App in Internet Explorer.

Steps to reproduce: Follow the docs for starting a new app (npm init stencil) and then either npm run build or npm run start with any combination of --prod --es5 and --dev always gives the same result.

Related code: Just the base starter code, no mods.

Other information: I came to the try just running the base starter app in IE because my Stencil components created with npm init stencil and choosing component don't work in IE either, presumably for the same reason (the flags don't actually do anything). Also note that running this script "start": "stencil build --dev --serve" (without --watch) does not actually start a server. I can create another ticket for this but I figured I'd mention it here since it help point towards a problem with the flags in general.

johnjenkins commented 3 years ago

Hi! Did you include the required polyfills? https://stenciljs.com/docs/config-extras

davidprae commented 3 years ago

Hey! I wasn't aware of that extras property but I just tried it out and it worked! 🙌

Maybe this helper screen should be updated. The Please see the example below or our config docs... makes it sound like all you need are the flags:

Screen Shot 2021-04-28 at 8 54 21 AM

Thanks a ton!

johnjenkins commented 3 years ago

yeah, agree. Those extras used to be bundled with an opt-out clause. Now they're opt-in. That page probably needs an update

splitinfinities commented 2 years ago

We updated this language as of v2.8.0! Thank you for calling this out!

splitinfinities commented 2 years ago

https://github.com/ionic-team/stencil/pull/2993 for reference!