类型“{}”上不存在属性“XXX”。ts(2339)
642661520 opened this issue · 1 comments
642661520 commented
Describe the bug
只要使用了setup ,在 template 中 使用的数据会提示 类型“{}”上不存在属性“XXX”。ts(2339)
Reproduction
<script lang="ts"> export default { data() { return { a: 11111, }; }, }; </script> <script setup lang="ts"> import { ref } from "@vue/composition-api"; const b = ref(1); </script> <style scoped> .logo { height: 6em; padding: 1.5em; will-change: filter; } .logo:hover { filter: drop-shadow(0 0 2em #646cffaa); } .logo.vue:hover { filter: drop-shadow(0 0 2em #42b883aa); } </style>System Info
vsCode
Used Package Manager
npm
Validations
- Follow our Code of Conduct
- Read the Contributing Guide.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
- The provided reproduction is a minimal reproducible of the bug.
Quan-HHH commented
How did you solve it? QAQ