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

runtime platform support #14

Open
sashafirsov opened this issue Jul 21, 2019 · 0 comments
Open

runtime platform support #14

sashafirsov opened this issue Jul 21, 2019 · 0 comments

Comments

@sashafirsov
Copy link
Member

There are multiple browsers with own capabilities on JS engine and available APIs application developers have to support. Build toolchains like webpack, various framework cli providing support for converting the source code to platform-specific compiled bundles. But in order to make cross-browser support efficient it is not enough to pick the lowest/oldest standard. On newer platforms with JS modules and web components the code would be a level of magnitude smaller and efficient if compiled accordingly. Which makes the platform-specific build switch so attractive.

The switch could be done by server side( web server filters ), CDN proxy rules, and finally by browser by JS. While embed-page supports dynamic switch of own content by pointing SRC attribute to appropriate build, EPA-WG should expose multiple ways of supporting this aspect of microapplication delivery via API, Docs, and reference implementation for platform-specific build switch of embed-page content.

polymer-cli, and other build toolchains allow to tune up the UI build for modern and legasy browsers. Here is a sample of bundle switch in JSP between build targetting es5 and es6 capable browsers.

The samples of build target switch to be extended to

  • apache config
  • cloudflare proxy
  • embed-page API use
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

1 participant