美文网首页
vue-chart js 的引用问题

vue-chart js 的引用问题

作者: 我是走A牧 | 来源:发表于2017-12-04 15:24 被阅读0次
<template>
  <div class="hello">
    <lin  :width="400"
          :height="heightY"></lin>
  </div>
</template>

<script>
  import lin from  "../assets/charts.js"
  export default {
    name: 'app',
    components: {
      lin:lin
    },
    data:function(){
      return {
//         heigthx:300,
//         heightY:0
      }
    },
    computed:{
      heightY:function(){ //
       let len=parseFloat(document.documentElement.style.fontSize);
        return  (600/75)*len
      }
    },
    mounted:function(){

    }
  }
</script>

<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>

</style>
图片.png

相关文章

网友评论

      本文标题:vue-chart js 的引用问题

      本文链接:https://www.haomeiwen.com/subject/hzdxixtx.html