Reputation: 63
I am working on a project and use c3 js library (don't use d3 js) And now I'm having a problem, that is when using c3 js, the x-axis of the graph will default to the bottom, but the design they want it to be above, so how do I handle it? Any help on how to achieve this would be greatly appreciated. Thanks every body
Upvotes: 0
Views: 272
Reputation: 3152
Can you set the axis min and Max to limit the displayed area? https://c3js.org/reference.html#api-axis-min
chart.axis.min({
x: -10,
y: 1000,
y2: 100
});
chart.axis.max({
x: 100,
y: 1000,
y2: 10000
});
Upvotes: 1