When using echart, it is clear that all parameters are passed in, but this. Is used in echart When init() initializes, it reports an error typeerror: axis Getaxesonzeroof is not a function. Through exclusion one by one, it is found that this error will occur when the data in the xaxis attribute is [].
Of course, my problem is not your problem, please analyze the specific problem!!!
My xaxis:
xAxis: {
type: 'category',
axisTick: {
alignWithLabel: true
},
data: data
}
Finally, my solution is:
if (this.data.length) {
this.dom.setOption(option);
} else {
this.dom.setOption({}); // Auto replace the first option
}
Read More:
- TypeError: r.indexOf is not a function TypeError: r.indexOf is not a function
- [Solved] Syntax Error: TypeError: this.getOptions is not a function
- [Solved] Less Install Error: TypeError: this.getOptions is not a function
- [Solved] Syntax Error: TypeError: this.getOptions is not a function
- [Vue warn]: Error in v-on handler: “TypeError: Object(…) is not a function“
- [Solved] webpack Package Error: TypeError: this.getOptions is not a function style-loader
- [Web Browser] “Uncaught TypeError: object is not a function“
- [Solved] node-xlsx Write excel Error: TypeError: n.indexOf is not a function
- [Solved] scss Error: TypeError: this.getOptions is not a function
- [Solved] Module build failed TypeError this.getOptions is not a function at Object.loader
- [Solved] Vue Error: Uncaught TypeError: Vue.createApp is not a function
- [Solved] Vue Route Error: Uncaught TypeError: (0 , vue__WEBPACK_IMPORTED_MODULE_42__.defineComponent) is not a function
- [Solved] Element Error: Error in render: TypeError: dateStr.match is not a function“
- [Solved] Vue Project Error: Syntax Error: TypeError: this.getOptions is not a function
- [Solved] Error in nextTick: “TypeError: undefined is not iterable
- [Solved] ESLint:TypeError: this.CliEngine is not a constructor
- [Solved] uni app TypeError: undefined is not an object (evaluating ‘modules[moduleId].call‘) __ERROR
- [Solved] Input error: this. Getoptions is not a function
- [Solved] Uncaught (in promise) TypeError: XXX.a is not a constructor
- ArcGIS API for JavaScript Error Uncaught(in promise): TypeError: xxx is not a constructor