vetur icon indicating copy to clipboard operation
vetur copied to clipboard

Update for <script setup> syntax

Open cimpok opened this issue 2 years ago • 2 comments

Vetur gives a false 'xxxx' is declared but its value is never read Vetur(6133) pop-up warning on import statements when the components: { ... } declatarion is missing, but the component is used in the template directly, which is an allowed shortcut in the new

cimpok avatar Nov 26 '21 15:11 cimpok

Personally, I recommend disabling the validation provided by Vetur and turning to use eslint explicitly with eslint-plugin-vue. I haven't tried myself, but from its documentation your case is supported. https://eslint.vuejs.org/user-guide/#does-not-work-well-with-script-setup

jzymx50 avatar Dec 02 '21 13:12 jzymx50

For the moment, I had to switch to Volar extension on VSCode. (edited: just saw it is the recommended extension for the moment as mentioned at the Vue3 official docs)

It is also worth to take a look at the VueDX extension.

Hope to turn back to Vetur straight away, as soon as it gets updated to support this new script setup syntax.

danb4r avatar Jan 23 '22 21:01 danb4r

Duplicate of https://github.com/vuejs/vetur/issues/2296

yoyo930021 avatar Nov 01 '22 11:11 yoyo930021