<template>
  <view class="index-page">
    <template v-if="isLogin">
      <index-logged />
    </template>
    <template v-else>
      <index-login />
    </template>
  </view>
</template>

<script>
import IndexLogged from '../components/Index/Logged'
import IndexLogin from '../components/Index/Login'
export default {
  name: 'Index',
  components: { IndexLogged, IndexLogin },
  data() {
    return {
      isLogin: false,
      loading: true
    }
  },
  computed: {},
  methods: {
  },
  async onShow() {
    this.isLogin = this.$api.user.isLogin()
  }
}
</script>

<style lang="scss" scoped>
.index-page {
}
</style>
