状态管理
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
<script setup>
|
||||
import { useUserStore } from '@/stores/user'
|
||||
|
||||
const user = useUserStore()
|
||||
|
||||
function t(){
|
||||
user.login();
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<template>
|
||||
test
|
||||
<button @click="t">222</button>
|
||||
{{ user.isLoggedIn }}
|
||||
</template>
|
||||
Reference in New Issue
Block a user