<template>
    <div class="hello">
        <chart ref="chart1" :options="orgOptions" :auto-resize="true" class="chart"></chart>
    </div>
</template>

<script>
export default {
    name: "HelloWorld",
    data() {
        return {
            orgOptions: {}
        };
    },
    mounted() {
        this.orgOptions = {
            xAxis: {
                type: "category",
                data: ["七分钟前", "六分钟前", "五分钟前", "四分钟前", "三分钟前", "两分钟前", "单前"]
            },
            yAxis: {
                type: "value",
                axisLabel: {
                    formatter: "{value} °C"
                },
                scale: true
            },
            series: [
                {
                    data: [32.5,32.6,32.4,32.5,32.4,32.6,32.4],
                    type: "line"
                }
            ]
        };
    }
};
</script>

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