vant-ui/vant-demo

read doc

roronoa-chen opened this issue · 0 comments

项目使用vue3,ts,vant3,使用vue-cli创建的项目,安装并配置了ts-import-plugin;

如果使用如下写法就会报错:

<template>
  <div class="home">
    <van-popup v-model:show="show"></van-popup>
  </div>
</template>

<script lang="ts">
import { defineComponent, ref } from 'vue';

export default defineComponent({
  name: 'Home',
});
</script>

<script setup lang="ts">
import { Popup } from 'vant';

const show = ref(true);
</script>

报错如下:
error

官方文案示例:
demo

标签使用有误,不再是van-开头