<template>
  <iframe :src="url" height="99.5%" width="100%" frameBorder="0" />
</template>
<script>
import { getToken } from '@/utils/auth'
export default {
  data() {
    return {
      token: getToken()
    }
  },
  computed: {
    url() {
      if (!!~this.$route.meta.url.indexOf('?x-token=')) {
        return this.$route.meta.url && this.token ? `${this.$route.meta.url}${this.token}` : ''
      } else {
        return this.$route.meta.url
      }
    }
  }
}
</script>
<style></style>
