-
Notifications
You must be signed in to change notification settings - Fork 14
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
TypeError: Cannot redefine property: Infinity #77
Comments
Thanks for taking the time to report this but unfortunately I don't have time to look into this right now due to paid work. PRs are very welcome. |
Hi @lukechilds could you merge my last pull request? If you don't have time, please assign write permissions to me. |
I think this is simply due to a simple bug in the index.js:
This works with a window object only based on the default settings, but adding a user JSDOM-config changes the window properties, which is why "Infinity" is not included in the protected properties. I guess this should rather read:
And in this case the const needs to be placed inside "browserEnv", below the declaration of "userJsdomConfig". You could of course also switch to a parametrized function and call that in the filter. |
Setting the jsdom option of
runScripts
with value of'dangerously'
causes the following exception:The text was updated successfully, but these errors were encountered: