forked from drone/command-center-dashboard

张含笑
2025-04-19 bdbef0fbde20317d19bfc6d3473dabb10fb3fb3b
src/views/TestTemplate.vue
@@ -1,12 +1,14 @@
<template></template>
<script setup>
import { useStore } from 'vuex';
const store = useStore();
// state必须带上.home
const singleUavHome = computed(() => store.state.home.singleUavHome);
// getters不需要带.home
const test = computed(() => store.getters.test);
onMounted(() => {
  // commit dispatch 不需要带.home
  store.commit('xxxx', '同步步修改啦');
@@ -22,6 +24,5 @@
);
</script>
<template></template>
<style scoped lang="scss"></style>