vuejs / language-tools

⚡ High-performance Vue language tooling based-on Volar.js
https://marketplace.visualstudio.com/items?itemName=Vue.volar
MIT License
5.55k stars 373 forks source link

Color is broken when <component> is in the same file #4407

Open jules-contact opened 1 month ago

jules-contact commented 1 month ago

I have a weird comportement when i have a tag in the same file

https://github.com/vuejs/language-tools/assets/65624014/a9f9f745-dd27-40f4-80bf-906f345ea02b

Repro :

<script setup lang="ts">
const bordered = defineProps({
  tag: {
    type: String,
    default: 'div',
  },
  background: {
    type: String,
  },
})
</script>

<template>
  <component
    :is="bordered.tag"
  >
    <slot />
  </component>
</template>