上一页 1 2 3 4 5 6 7 8 9 ··· 18 下一页
摘要: 表单输入绑定v-model <!-- 表单输入绑定 FromInputBinding.vue --> <template> <h3>表单输入绑定</h3> <form action=""> <!-- 简单理解就是v-bind绑定的是单向绑定 --> <!-- v-model绑定的是双向绑定,修改一边 阅读全文
posted @ 2025-04-28 16:13 guixiang 阅读(17) 评论(0) 推荐(0)
摘要: 侦听器 代码 <!-- ListenerDemo.vue 事件监听--> <template> <p>事件监听--响应示监听</p> <h1>{{ message }}</h1> <button @click="UpdateHandle">修改数据</button> </template> <scr 阅读全文
posted @ 2025-04-28 15:40 guixiang 阅读(20) 评论(0) 推荐(0)
摘要: 计算属性-vue <!-- calculation_properties.vue --> <template> <h3>{{ items.name }}</h3> <!-- <p>{{ Object.keys(items.content).length > 0 ? 'Yes':'No' }}</p> 阅读全文
posted @ 2025-04-24 21:25 guixiang 阅读(14) 评论(0) 推荐(0)
摘要: class绑定 <!-- Class样式绑定 --> <template> <p :class="{ 'ClassBinding': isActive }">Class样式绑定</p> <p :class="{ 'ClassBinding': !isActive }">Class样式绑定</p> < 阅读全文
posted @ 2025-04-24 21:24 guixiang 阅读(11) 评论(0) 推荐(0)
摘要: 数组变化侦测 代码 <template> <h3>数组侦听</h3> <ul> <li v-for="(item,index) in names" :key="index">{{ item }}</li> </ul> <button @click="addlistHandle">添加数据(ui自动更 阅读全文
posted @ 2025-04-23 21:22 guixiang 阅读(14) 评论(0) 推荐(0)
摘要: 事件修饰符:简化代码 代码 <!-- EventModification.vue --> <template> <p>事件修饰符</p> <a @click="clickHandle" href="www.baidu.com">baidu(点击之后可以跳转)</a> <p></p> <a @clic 阅读全文
posted @ 2025-04-23 20:59 guixiang 阅读(11) 评论(0) 推荐(0)
摘要: 事件传参 源码 <!-- EventProcessingAbabdemo3.vue --> <template> <button @click="addCount('hello')">ADD</button> <p>count is {{ count }}</p> <p @click="getnam 阅读全文
posted @ 2025-04-23 19:46 guixiang 阅读(9) 评论(0) 推荐(0)
摘要: 事件处理 代码: <!-- EventProcessingAbabdemo2.vue --> <template> <button @click="addCount">ADD</button> <p>count is {{ count }}</p> </template> <script setup 阅读全文
posted @ 2025-04-23 19:24 guixiang 阅读(17) 评论(0) 推荐(0)
摘要: v-for/item in items列表渲染加css样式分离 代码 <!-- ListDemo.vue --> <template> <div> <h1>列表渲染</h1> <p v-for="(item, index) in list" :key="index">{{ item }}</p> < 阅读全文
posted @ 2025-04-20 21:11 guixiang 阅读(23) 评论(0) 推荐(0)
摘要: 最新版vue文件讲解和端口修改 . ├── src/views # 页面视图组件 │ ├── AboutView.vue # 关于页面 │ └── HomeView.vue # 主页 ├── src/assets # 静态资源文件 │ ├── base.css # 全局样式 │ └── main.c 阅读全文
posted @ 2025-04-20 20:24 guixiang 阅读(29) 评论(0) 推荐(0)
上一页 1 2 3 4 5 6 7 8 9 ··· 18 下一页