-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
CodeFix to import entire module into single variable #13295
Comments
This comment seems relevant leebyron/ecmascript-more-export-from#11 (comment) Specifically the performance characteristics of this pattern are perhaps significant. |
I wonder if this could be fixed relatively easily by piggybacking on the exports from the module. For instance, in the screenshot that @normalser provided, he requests a specific property of the bluebird file. If you take off the |
See the OP. The request is to import an entire module into one variable, not to import one export of a module. |
That'll be nice for refactoring. I think this issue is still useful for writing the code, as that code fix will be more of a workaround since it takes more steps. I can imagine being used to using the namespace import in one file and then moving to another and starting to do it that way, but it's not imported yet. There's no code fix for that, so then you have to first import the child, then change it to a namespace import at the top of the file. I could also imagine copying code that uses the namespace style and having to do the workaround for that as well. As a result I still think this issue is worth keeping, even if it's implemented a long way down the road. |
This doesn't seem to be a common request. |
Was this a duplicate of #23830? |
Not sure if this would be possible but it would be nice if one could import entire module into single variable.
For example CodeFix on
bluebird
or onmapSeries
would offer
import * as bluebird from 'bluebird'
The text was updated successfully, but these errors were encountered: