How does echarts fix the x-axis above

I want to fix the x-axis of an ordinary line chart (considering only the existence of one X-axis) at the top, because the x-axis defaults to the

below.

clipboard.png


top

clipboard.png

I adjusted {position: "top"} and that"s it. AxisLine and axisTick are at the bottom, only the text goes up. -.


I think you want this effect.
clipboard.png

@ Miziko

option = {
    xAxis: {
        position: 'top',
        type: 'category',
        data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
        axisLine: {
            onZero: false
        }
    },
    yAxis: {
        inverse: true,
        type: 'value'
    },
    series: [{
        data: [820, 932, 901, 934, 1290, 1330, 1320],
        type: 'line'
    }]
};

Boss code can't be seen clearly,

    positoin:'top'
    axisLine:{
        onIere:false
    }onIere
Menu