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

Check if requestIdleCallback exists in window #112

Merged
merged 1 commit into from
Aug 6, 2019

Conversation

dieulot
Copy link
Contributor

@dieulot dieulot commented Jul 30, 2019

Fixes the following error when not transpiled:

Uncaught ReferenceError: Cannot access 'requestIdleCallback' before initialization
at request-idle-callback.mjs:18

It doesn’t throw when being transpiled to ES5 because it uses var instead of const.

Fixes the following error when not transpiled:
> Uncaught ReferenceError: Cannot access 'requestIdleCallback' before initialization
>   at request-idle-callback.mjs:18
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.

2 participants