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

Install polyfill if clearImmediate is undefined #71

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

robwalch
Copy link

At JW Player we've found sites that have setImmediate polyfilled without clearImmediate. This breaks our player's embed because it's compiled with webpack which depends on this module as a sub-dependency.

Checking that both setImmediate and clearImmediate are defined before exiting ensures that the polyfill is always attached when needed.

@robwalch
Copy link
Author

@domenic are you maintaining this project? If there's anything I can do to contribute towards getting a patch please let me know. Thanks!

@robwalch
Copy link
Author

On a side note, we'll be resolving the issue in our library by configuring webpack to not polyfill node modules (webpack node: false). promise-polyfill attempts to use setImmediate if defined, but that prompts webpack to polyfill setImmediate.

@robwalch
Copy link
Author

ping

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

Successfully merging this pull request may close these issues.

1 participant