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

auto import problem #2850

Open
fuxichen opened this issue Apr 8, 2021 · 6 comments
Open

auto import problem #2850

fuxichen opened this issue Apr 8, 2021 · 6 comments

Comments

@fuxichen
Copy link

fuxichen commented Apr 8, 2021

Info

  • Platform: Win10
  • Vetur version: 0.33.1
  • VS Code version: 1.55.0

Problem

Hello, I recently encountered a problem. Vetur's auto import is importing nodes_ The path of the file in modules will change to node_modules/vue/dist/vue
image
image

It should be normal
image

Look forward to your reply,thank you!

Reproducible Case

@yoyo930021
Copy link
Member

What content is your tsconfig.json?

@fuxichen
Copy link
Author

fuxichen commented Apr 9, 2021

What content is your tsconfig.json?

是vuecli 生成的vue3+ts默认内容
It is the default content of vue3 + TS generated by vuecli
image

@yoyo930021
Copy link
Member

Please provide a repro case.
https://github.com/vuejs/vetur/blob/master/.github/NO_REPRO_CASE.md.

@fuxichen
Copy link
Author

请提供一个复制案例。
https://github.com/vuejs/vetur/blob/master/.github/NO_REPRO_CASE.md。
我克隆了https://github.com/octref/veturpack project这个项目,并且使用虚拟机安装了一个全新的vscode和vetur。没有修改任何内容,但是还是出现了该问题
I cloned the https://github.com/octref/veturpack project and installed a new vscode and vetur using the virtual machine. Nothing was changed, but the problem still occurred
image
image
image
image
image

@fuxichen
Copy link
Author

fuxichen commented Apr 10, 2021

你好,我将vetur版本降级到0.32.0,这个问题就解决了。感谢您的帮助!
我期待着您在新版本中发现并解决这个问题。
Hello, I downgraded the version of vetur to 0.32.0, and this problem was solved. Thank you for your help!
I look forward to your finding and solving this problem in the new version。
image
image

@yoyo930021
Copy link
Member

yoyo930021 commented Apr 10, 2021

I can't repro it.
截圖 2021-04-11 上午12 09 26

and this question isn't in vetur, It is an upstream problem in typescript.
You can try to use next release vetur. vetur will upgrade typescript to the latest.
Or use vetur.useWorkspaceDependencies: true for using custom typescript version.

You can open an issue to typescript project when the existing problem the latest typescript version.

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

2 participants