This commit is contained in:
syuilo
2018-10-19 11:10:49 +09:00
parent f028800a96
commit f14c372f5e
7 changed files with 55 additions and 20 deletions

View File

@@ -1,16 +1,25 @@
<template>
<component :is="$store.getters.isSignedIn ? 'home' : 'welcome'"></component>
<component :is="page"></component>
</template>
<script lang="ts">
import Vue from 'vue';
import Home from './home.vue';
import Welcome from './welcome.vue';
import Deck from './deck/deck.vue';
export default Vue.extend({
components: {
Home,
Deck,
Welcome
},
computed: {
page(): string {
if (!this.$store.getters.isSignedIn) return 'welcome';
return this.$store.state.device.deckDefault ? 'deck' : 'home';
}
}
});
</script>