Comments (9)
Hi @humpangle, please install @vue/runtime-dom
for vue 2 project. See https://github.com/johnsoncodehk/volar#using.
from coc-volar.
I have raised the issue with @vue/composition-api
. @yaegassy , would you like me to close this issue?
from coc-volar.
Does this problem also occur with VSCode's volar extension?
If possible, could you please provide the smallest code sample you can reproduce?
If downgrading the version of coc-volar temporarily solves your problem, please give it a try.
:CocUninstall @yaegassy/coc-volar
:CocInstall @yaegassy/[email protected]
from coc-volar.
Thanks for the response. Downgrading to 0.5.9 did make the errors go away, but then there is no longer intellisense. You can take a look here https://github.com/humpangle/non-typescript-vue-coc-volar/blob/36d29889a43d7406a803929854f75a794fda93b3/src/components/HelloWorld.vue#L2
You will get errors for both the sayHi
callback and the msg
prop.
Below are my coc-volar
and vue related settings:
"volar.codeLens.references": false,
"volar.codeLens.pugTools": false,
"volar.codeLens.scriptSetupTools": false,
"volar.formatting.enable": false,
"prettier.disableLanguages": [],
"emmet.includeLanguages": {
"vue-html": "html",
}
from coc-volar.
By installing @vue/runtime-dom
, the error was resolved in my environment. (coc-volar v0.5.10
)
@humpangle Did you solve the problem?
Downgrading to 0.5.9 did make the errors go away, but then there is no longer intellisense.
As a side note, coc-volar v0.5.9 (volar v0.27.6) or earlier, required tsconfig.json
or jsconfig.json
in the project.
from coc-volar.
Thanks @johnsoncodehk and @yaegassy . I have installed @vue/runtime-dom
as suggested and that made the errors go away.
But I have found the problem is with @vue/composition-api
. If you look at the repo https://github.com/humpangle/non-typescript-vue-coc-volar
in commit 624c5f5 where I introduced @vue/composition-api
here https://github.com/humpangle/non-typescript-vue-coc-volar/blob/624c5f56abecb53164ba90745a902e6cd6fb4b5c/src/components/Some.vue#L8
, then I started getting the same callback error as in my actual project.
Here is the location of the error https://github.com/humpangle/non-typescript-vue-coc-volar/blob/624c5f56abecb53164ba90745a902e6cd6fb4b5c/src/components/HelloWorld.vue#L2
.
The error message:
[ts 2322] [E] Type 'any' is not assignable to type 'never'.
from coc-volar.
It's seem a bug, please forward @vue/composition-api
types issue to @vue/composition-api
repo.
from coc-volar.
Thanks @johnsoncodehk. I will do just that right away.
But should I be getting type issues in a non TS project? Apologies if I should have found the answer some where.
from coc-volar.
Thanks @johnsoncodehk. I will do just that right away.
But should I be getting type issues in a non TS project? Apologies if I should have found the answer some where.
Maybe follow vuejs/language-tools#411.
from coc-volar.
Related Issues (20)
- Custom diagnostics icon or use coc diagnostics icon HOT 2
- Getting [ts 2339] [E] Property '...' does not exist on type HOT 8
- Add Configuration for Packer HOT 1
- [0.24.0] Volar not detecting template in script setup HOT 4
- Does not work with ts files HOT 3
- `:CocCommand volar.initializeTakeOverMode` get an error!! HOT 2
- notarget No matching version found for @volar/[email protected] HOT 2
- It seems that ‘@’ completion is not supported? HOT 6
- How to how tsserver commands in takeover mode. HOT 2
- does coc-volar do any intellisense inside template and css block HOT 5
- deprecated dependency HOT 1
- Some CodeActions cannot be executed due to errors HOT 6
- the diagnostic can't be used HOT 7
- file path completion when resolve alias with '@' HOT 2
- Cannot jump to component without `.vue` file extension HOT 1
- Language server does not recognize files that have been added or changed HOT 20
- syntax highlight randomly crashed when editing/scrolling through vue SFC HOT 2
- Diagnostic issue (not showing) HOT 4
- Disable autocompletion source HOT 2
- How to install using self managed registry. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coc-volar.