jormungandr-bite/src/client/app/desktop/views/pages/index.vue

26 lines
457 B
Vue
Raw Normal View History

2018-02-09 22:56:33 -07:00
<template>
2018-10-18 20:10:49 -06:00
<component :is="page"></component>
2018-02-09 22:56:33 -07:00
</template>
<script lang="ts">
import Vue from 'vue';
2018-02-20 09:39:51 -07:00
import Home from './home.vue';
import Welcome from './welcome.vue';
2018-10-18 20:10:49 -06:00
import Deck from './deck/deck.vue';
2018-02-09 22:56:33 -07:00
export default Vue.extend({
components: {
2018-02-20 09:39:51 -07:00
Home,
2018-10-18 20:10:49 -06:00
Deck,
2018-02-20 09:39:51 -07:00
Welcome
2018-10-18 20:10:49 -06:00
},
computed: {
page(): string {
if (!this.$store.getters.isSignedIn) return 'welcome';
return this.$store.state.device.deckDefault ? 'deck' : 'home';
}
2018-02-09 22:56:33 -07:00
}
});
</script>