缺少中间两个
xAxis: [
{
type: "category",
data: [
"x1x1x1x1x1x1",
"x2x2x2x2x2x2",
"x3x3x3x3x3x3",
"x4x4x4x4x4x4",
"x5x5x5x5x5x5",
],
nameTextStyle: {
color: "#386BFF",
},
axisLine: {
lineStyle: {
color: "rgba(57,108,255, 0.2)",
},
},
axisLabel: {
color: "#386BFF",
},
},
],
解决:
xAxis: [
{
type: "category",
data: [
"x1x1x1x1x1x1",
"x2x2x2x2x2x2",
"x3x3x3x3x3x3",
"x4x4x4x4x4x4",
"x5x5x5x5x5x5",
],
nameTextStyle: {
color: "#386BFF",
},
axisLine: {
lineStyle: {
color: "rgba(57,108,255, 0.2)",
},
},
axisLabel: {
interval: 0, //去除间隙 刻度间隔为0
color: "#386BFF",
},
},
],