coc.nvim 中 coc-tsserver 和 coc-volar 在 vue 项目打开 ts 后缀文件冲突解决方案

If you are using "Take Over Mode" for the first time in your project

To begin, open the *.vue, *.ts, *.js, *.tsx, *.jsx file.
Then run :CocCommand volar.initializeTakeOverMode.
When prompted by Enable Take Over Mode? (y/n)?, enter y
The .vim/coc-settings.json file will be created in the "project root".
The "volar.takeOverMode.enabled": true and "tsserver.enable": false settings will be added.
coc.nvim will be restarted and the settings will be reflected.

If you want to disable Take Over Mode for a project

Delete the .vim/coc-settings.json file in the "project root", and start Vim again.

参考:

https://github.com/yaegassy/coc-volar

posted @ 2023-01-31 12:32  3yude  阅读(119)  评论(0)    收藏  举报