<template>
  <view ref="echartRef" id="chart"></view>
</template>

<script>
import * as echarts from '@/uni_modules/s-echarts/echarts.min.js'
export default {
  name: 'cs-echart',
  data() {
    return {
      echart: null
    }
  },
  mounted() {
    this.init()
  },
  methods: {
    init() {
      this.echart = echarts.init(this.$refs.echartRef)
    }
  }
}
</script>

<style lang="scss" scoped>
.chart {
  width: 100%;
  height: 100%;
}
</style>
