LoadMapUser.vue 363 B

1234567891011121314151617
  1. <script setup lang="ts">
  2. import {storeToRefs} from "pinia";
  3. import {useUserStore} from "@/store/userStore";
  4. interface IProps {
  5. userId: string
  6. }
  7. const props = defineProps<IProps>();
  8. const {userMap} = storeToRefs(useUserStore())
  9. if (userMap.value.get(props.userId) === undefined) {
  10. useUserStore().loadMapUser(props.userId)
  11. }
  12. </script>
  13. <template>
  14. </template>