Files
xl-mobile/src/App.vue
2025-06-26 20:25:32 +08:00

28 lines
670 B
Vue

<script>
import {useUserStore} from "./pinia/UserStore/index.js";
import {toPage} from "./utils/uils.js";
export default {
onLaunch: function () {
},
onShow: function () {
// #ifndef MP-WEIXIN
const UserStore = useUserStore();
if (!UserStore.isLogin && window.location.href.indexOf('/pages/register/index') < 0 && window.location.href.indexOf('/pages/fastInput/index') < 0) {
toPage('/pages/login/index');
}
// #endif
},
onHide: function () {
},
}
</script>
<style>
/* #ifdef MP-WEIXIN */
@import "weapp-tailwindcss/css";
@source not "dist";
/* #endif */
</style>