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

Can't resolve imports where file name contains multiple dots but no .js in the end #26

Closed
kkogovsek opened this issue Feb 15, 2020 · 3 comments

Comments

@kkogovsek
Copy link

Example output:

Could not resolve import:  [ '/cant/share/folder/structure/useForm.js',
  '../../services/logger.service' ]
@AnatoleLucet
Copy link
Collaborator

AnatoleLucet commented Feb 15, 2020

Do you have an import written with a leading slash in your code? /cant/share/folder/structure/useForm.js
If yes, this is probably because of how we use Node's path.resolve(). This could be fixed with a simple condition.

But still, what do you mean by where file name contains multiple dots but no .js in the end, are you speaking about backward dots (../) in your second path? Anyway, can you provide a bit more infos in your issue. Like your files structure, the bugged imports in your code, and more if you have... Thanks you.

@benawad
Copy link
Owner

benawad commented Feb 16, 2020

@kkogovsek give destiny a try, I just published it with a bunch of changes including a better resolve algorithm.

@sQVe
Copy link
Collaborator

sQVe commented Feb 20, 2020

Closing due to lack of feedback.

@kkogovsek If you're still having problems give me a ping and I'll reopen!

@sQVe sQVe closed this as completed Feb 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants