<template>
  <div class="project">
    <h1>{{ title }}</h1>
    <p>{{ description }}</p>
  </div>
</template>
<script setup lang="ts">
import { defineComponent } from 'vue'
import { useStore } from 'pinia'
import { useMouse } from '@vueuse/core'

const title = '开发项目'
const description = '使用 Yarn、Vite、Vue 3、TypeScript、Pinia 和 Vueuse 工具'

const store = useStore()

const { x, y } = useMouse()

console.log(store.state)

</script>
<style scoped>
.project {
  font-size: 24px;
  text-align: center;
  color: #333;
}
</style
Create a Vue 3 component that displays a 开发项目 using Yarn Vite Vue 3 TypeScript Pinia and Vueuse tools Use Vue 3s Composition API and script setup syntax to combine template script and style in a singl

原文地址: http://www.cveoy.top/t/topic/hnWq 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录