-
-
Notifications
You must be signed in to change notification settings - Fork 43
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
fix: Use original plugin from disk in FlatCompat #137
Conversation
Looks like there's currently a problem with the GitHub CI services as it can't download Node.js. Will try re-running jobs in a bit. |
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.
CI works now. Looks good, aside from one detail.
definition: _ignore1, // eslint-disable-line no-unused-vars | ||
original: _ignore2, // eslint-disable-line no-unused-vars |
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.
Seems like https://eslint.org/docs/latest/rules/no-unused-vars#varsignorepattern could be useful here, and then you can do something like
definition: _ignore1, // eslint-disable-line no-unused-vars | |
original: _ignore2, // eslint-disable-line no-unused-vars | |
definition: _, | |
original: __, |
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.
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.
LGTM, thanks!
This switches
FlatCompat
to use the original (unnormalized) version of the plugin that was loaded from disk rather than the normalized version. This ensures that we'll avoid plugin redefinition errors when folks are using bothFlatCompat
and their own imports.Fixes #135