<script setup lang="ts">
import { RouterView } from "vue-router";
import { useWindowStore } from "./store/window";
import { storeToRefs } from "pinia";
import { onMounted } from "vue";

const windowStore = useWindowStore();
const { innerWidth, innerHeight } = storeToRefs(windowStore);

onMounted(() => {
  window.addEventListener("resize", () => {
    innerWidth.value = window.innerWidth;
    innerHeight.value = window.innerHeight;
  });
});
</script>

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

<style scoped></style>
