<script setup lang="ts">
import { onLaunch, onShow, onHide } from "@dcloudio/uni-app";
// const isFirstLaunch = ref(true);

onLaunch(() => {
  // console.log(Boolean(uni.getStorageSync("hasLaunched")))
  // // 当应用启动时，检查是否已显示过启动页
  // if (Boolean(uni.getStorageSync("hasLaunched"))) {
  //   // 如果已显示过，不再显示启动页
  //   isFirstLaunch.value = false;
  //   console.log("不再显示启动页");
  // } else {
    
  //   // 如果未显示过，标记为已显示，并保存到存储
  //   uni.redirectTo({ url: "pagesLaunch/index" });
  //   uni.setStorageSync("hasLaunched", true);
  //   console.log('******* 执行啦')
  // }
});
onShow(() => {
  console.log("App Show");
});
onHide(() => {
  console.log("App Hide");
});
</script>

<style lang="scss">
/* 注意要写在第一行，同时给style标签加入lang="scss"属性 */
@import "uview-plus/index.scss";
body {
  font-size: 12px;
}
</style>
