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

Duplicate imports #43

Open
OliverJAsh opened this issue Dec 14, 2016 · 2 comments
Open

Duplicate imports #43

OliverJAsh opened this issue Dec 14, 2016 · 2 comments

Comments

@OliverJAsh
Copy link

OliverJAsh commented Dec 14, 2016

When I have existing imports from ../foo, any auto completions for exports in this module will add another import from ./../foo.

E.g.

import { x } from '../foo';
// after auto importing y…
import { y } from './../foo';

Expected:

// after auto importing y…
import { x, y } from '../foo';

This may be related to #37

@kylecordes
Copy link

BTW, over on another project there is a library design discussion underway. One topic that has come up is that if a library exports a symbol from only one place, tooling (like this) has no way to import it from the "wrong" place.

@Undistraction
Copy link

Undistraction commented Jan 11, 2018

For some npm modules I have more than two options:

  • lib/index.js
  • dist/example.js
  • src/path/to/file.js
  • src/index.js

I think even if there was only a unique export from the index, it would still be picked up from lib and dist.

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

No branches or pull requests

3 participants