<script lang="ts">
import { ref, defineComponent, reactive, toRefs, watch, onMounted } from "vue";
import useProjectStore from "@/store/useProjectStore";

export default defineComponent({
    setup() {
        const projectStore = useProjectStore();
        onMounted(() => {
            
             
            //这两个请求不能写在这里  因为router.beforeEach 发生在后面，获取不到projectId
            // projectStore.setWeather();
            // projectStore.setProjectObj();
        });

        watch(projectStore.$state, (nstate, ostate) => {
            //console.log(nstate.projectId, ostate.projectId);
           // debugger;
        });
    },
});
</script>

<template>
    <router-view></router-view>
</template>

<style scoped lang="scss">

#app {
    font-family: Avenir, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  
    // background: #f3fdff;
    //   text-align: center;
    //   color: #2c3e50;
    //   margin-top: 60px;
}
</style>
