<template>
  <div id="">
    <component :is="currentComponent(header.templateStatus)"></component>
  </div>
</template>

<script>
import { mapGetters } from "vuex";
import home1 from "../home1/index.vue";
import home2 from "../home2/index.vue";
export default {
  components: { home1, home2 },
  data() {
    return {};
  },
  created() {},
  computed: {
    ...mapGetters(["header"]),
    currentComponent: function() {
      return function(int) {
        var str = "";
        switch (int) {
          case 1:
            str = "home1";
            break;
          case 2:
            str = "home2";
            break;

          default:
            str = "home1";
            break;
        }
        return str;
      };
    }
  },
  methods: {}
};
</script>

<style lang="scss" scoped></style>
