会员
周边
新闻
博问
融资
云市场
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
前端_蜡笔小新欢迎您
前端_蜡笔小新欢迎您
博客园
首页
新随笔
联系
订阅
管理
上一页
1
2
3
4
5
6
7
8
9
···
29
下一页
2022年9月7日
小程序 : 请求,数据,事件,上拉加载下拉刷新
摘要: // pages/profile/profile.js Page({ //数据 data: { avatarURL: "", listCount: 30 }, // 监听下拉刷新 onPullDownRefresh() { console.log("用户进行下拉刷新~"); // 模拟网络请求: 定
阅读全文
posted @ 2022-09-07 11:05 杨建鑫
阅读(21)
评论(0)
推荐(0)
编辑
app.js文件
摘要:
阅读全文
posted @ 2022-09-07 10:57 杨建鑫
阅读(13)
评论(0)
推荐(0)
编辑
2022年8月31日
vue项目-vite+pinia
摘要: 1
阅读全文
posted @ 2022-08-31 15:19 杨建鑫
阅读(8)
评论(0)
推荐(0)
编辑
vue3+pinia 的 actions
摘要: 使用<template> import { defineStore } from 'pinia' // 用到其他store的信息 import useCounter from './counter' const useUser = defineStore('user',{ state:()=>({
阅读全文
posted @ 2022-08-31 10:28 杨建鑫
阅读(591)
评论(0)
推荐(0)
编辑
state 和 getters 的代码实例
摘要: 使用 : <template> <div class="id"> <h3>姓名: {{ userStore.name }}</h3> <h3>年龄: {{ userStore.age }}</h3> <h3>等级: {{ userStore.level }}</h3> <h3>简化版姓名: {{ n
阅读全文
posted @ 2022-08-31 09:51 杨建鑫
阅读(5)
评论(0)
推荐(0)
编辑
2022年8月30日
vue3+ pinia 的初实用
摘要: 固定不变的 : stores/index.js import { createPinia } from "pinia" const pinia = createPinia() export default pinia main.js import { createApp } from 'vue' i
阅读全文
posted @ 2022-08-30 16:08 杨建鑫
阅读(61)
评论(0)
推荐(0)
编辑
vue2和vue3的modules :
摘要: store/modules/home.js export default { state: { // 服务器数据 banners: [], recommends: [] }, mutations: { changeBanners(state, banners) { state.banners = b
阅读全文
posted @ 2022-08-30 14:13 杨建鑫
阅读(67)
评论(0)
推荐(0)
编辑
vue3+vuex 的 action 来发送网络请求的
摘要: <template> <div class="app"> <h3>Home Page</h3> <ul> <template v-for="item in $store.state.banners" :key="item.acm"> <li>{{ item.title }}</li> </templ
阅读全文
posted @ 2022-08-30 13:47 杨建鑫
阅读(148)
评论(0)
推荐(0)
编辑
公司
摘要:
阅读全文
posted @ 2022-08-30 11:20 杨建鑫
阅读(8)
评论(0)
推荐(0)
编辑
vue3+vuex 的 actions 的 使用
摘要: <template> <div class="app"> 姓名:{{$store.state.nameVuex}} <button @click="btn">基本方法 : 修改名字</button> <br/> <button @click="btn1">传递值 : 修改名字</button> <h
阅读全文
posted @ 2022-08-30 10:53 杨建鑫
阅读(345)
评论(0)
推荐(0)
编辑
上一页
1
2
3
4
5
6
7
8
9
···
29
下一页
公告