上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 21 下一页
摘要: 逻辑复用-组合式函数 src/views/ad/User.vue <script setup> import { useMouse } from "../../js/mouse.js"; import { useFetch } from "../../js/fetch.js"; import { r 阅读全文
posted @ 2023-12-26 16:10 carol2014 阅读(26) 评论(0) 推荐(0) 编辑
摘要: 组件 src/views/ad/Comp.vue <script setup> import { ref, provide, readonly, defineAsyncComponent } from "vue"; import DemoComp from "../../components/sim 阅读全文
posted @ 2023-12-26 15:54 carol2014 阅读(15) 评论(0) 推荐(0) 编辑
摘要: 响应式状态 src/views/basic/Reactive.vue <script setup> import { ref, reactive, computed, watch, watchEffect } from "vue"; //reactive 响应式对象 只能用于对象、数组和集合类型 c 阅读全文
posted @ 2023-12-26 15:23 carol2014 阅读(21) 评论(0) 推荐(0) 编辑
摘要: 事件绑定 src/views/basic/Event.vue <script setup> import { nextTick, ref } from "vue"; function clickA() { console.log("点击了a标签,点击事件传递到了外层p标签"); } function 阅读全文
posted @ 2023-12-26 15:17 carol2014 阅读(83) 评论(0) 推荐(0) 编辑
摘要: 表单相关 src/views/basic/Form.vue <script setup> import { ref } from "vue"; const message = ref("hello"); const checked = ref(); const checkedNames = ref( 阅读全文
posted @ 2023-12-26 15:04 carol2014 阅读(11) 评论(0) 推荐(0) 编辑
摘要: 模板语法 src/views/basic/Template.vue <script setup> import { ref, reactive, onMounted } from "vue"; //模板语法 const msg = "hello"; const rawHtml = "<span st 阅读全文
posted @ 2023-12-26 15:00 carol2014 阅读(30) 评论(0) 推荐(0) 编辑
摘要: 我的vue3学习之路总是学学停停,最开始在18年开发微信小程序,就发现小程序和vue的语法有些相似,然后就去看了vue2的文档,随后忙其它的事情就丢下了。 直到22年又开始捡起来vue3,有了组合式api,语法简明很多,然后又不知道忙什么丢下。。。 前段有些空时间,就把vue3的学习整理下,使用vi 阅读全文
posted @ 2023-12-26 14:55 carol2014 阅读(38) 评论(0) 推荐(0) 编辑
摘要: 这次是被坑了,在linux apache运行完好的代码放到IIS服务器上居然没有数据,检查发现居然出现了419错误,要求ajax post请求中应该包含csrf token字段。 然后就突然想起来了,上次相似的项目也发生过这样的问题,上次没记录,时日长久,这次居然一点儿也没想起来... 按照错误提示 阅读全文
posted @ 2023-12-26 10:33 carol2014 阅读(91) 评论(0) 推荐(0) 编辑
摘要: 表单输入绑定 <!-- 文本 (Text) --> <input v-model="message" placeholder="edit me" /> <p>Message is: {{ message }}</p> <!-- 多行文本 (Textarea) --> <textarea v-mode 阅读全文
posted @ 2023-12-20 16:28 carol2014 阅读(4) 评论(0) 推荐(0) 编辑
摘要: HTML5 dialog标签简单使用 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1 阅读全文
posted @ 2023-12-20 16:05 carol2014 阅读(92) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 21 下一页