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
chore(lint): disallow Math.hypot
, window
, document
#8277
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why doesn't the lint job detect the error?
It does on my machine
Math.hypot
Math.hypot
, 'window,
document`
Math.hypot
, 'window,
document`Math.hypot
, window
, document
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The window
rule will fail as long as there are existing cjs export directives
})(typeof exports !== 'undefined' ? exports : window);
ok, is fine anyway, even if window fails for now. |
I found out how to use no-restricted-syntax to match
Math.hypot
and no-restricted-globals to matchwindow
anddocument
Motivation
https://stackoverflow.com/questions/62931950/different-results-of-math-hypot-on-chrome-and-firefox
In Action