testcase
This commit is contained in:
parent
00a00161fa
commit
023b4e34f5
|
|
@ -3,14 +3,16 @@ import {defineStore} from "pinia";
|
||||||
const useStore = defineStore("mon",{
|
const useStore = defineStore("mon",{
|
||||||
state(){
|
state(){
|
||||||
return {
|
return {
|
||||||
username: "乔文章"
|
username: ""
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
//触发动作
|
||||||
actions:{
|
actions:{
|
||||||
Update(username){
|
Update(username){
|
||||||
this.username = username
|
this.username = username
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
//持久化存储,默认存储全部的数据
|
||||||
persist: {
|
persist: {
|
||||||
enabled: true,
|
enabled: true,
|
||||||
strategies: [{
|
strategies: [{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue