-
Notifications
You must be signed in to change notification settings - Fork 78
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
Fixing the consistency of shim #279
Comments
I agree that shim is a confused suite of modules that operate in different ways and with different principles.
|
@agubler pretty much hit everything I was thinking. I think we should auto bundle everything for IE and then for newer platform features have them under a |
Self assigning this as I'm working on converting the legacy shims to work as polyfills while still being usable directly. This won't address the entirety of the issue though. |
The majority of this initiative has been completed, for the remainder targeted issues will be raised. |
This is larger discussion on how we can get
shim
to a level of consistency that is reasonable. At the moment the things in shim wildly vary so I will try and explain whats there.To start with we have a number of shims what I think we can now tag as "legacy" that are only required in IE11, these I think are:
and
I have split these into 2 groups. The first group we can easily polyfill onto the global, but the second are currently actual shims that would normally be on the associated primitive's prototype. These shims are quite annoying as they obviously have different api's to the native versions which means remembering to use the shim exclusively if targeting a legacy environment. In an ideal scenario I think at this point these should all be transparent polyfills we can apply at build time automatically in legacy modes?
For the rest of this repo (which isn't a lot taking into account all the legacy for IE11 above), the majority of things in here are Web Platform polyfills, ie:
These are fundamentally different to the other things in shim, they a) are mostly wrappers around polyfills from the community b) are applied to the window, as we have no control of the implementation.
Other shims which are not Web Platform polyfills:
Given all the information above, i'd like for us to discuss how we should go about structuring these what I think are separate things better in the repo, some open questions:
core
.The text was updated successfully, but these errors were encountered: