score:16
Accepted answer
it can be done using the maxtickslimit
option of xaxes, see this working fiddle -> http://jsfiddle.net/lzo5g01n/3/
xaxes: [{
type: 'time',
ticks: {
autoskip: true,
maxtickslimit: 20
}
}]
score:2
for chart.js 3.3.2, you can use @kunal khivensara's approach with a few changes. you can check the documentation. put ticks
in xaxis
in scales
. example:
...
options: {
scales: {
xaxis: {
ticks: {
maxtickslimit: 10
}
}
}
}
...
Source: stackoverflow.com
Related Query
- How do I change the 'months' language displayed on the date axis in Chart JS?
- How to change text colour of specific labels of axis in Chart JS?
- Chart Js change text label orientation on Ox axis
- How to change X-Axis Interval on Chart.js
- Chart js. How to change font styles for "labels" array?
- How to hide the y axis and x axis line and label in my bar chart for chart.js
- how to change Y axis value dynamically based on user input in Chartjs for Line chart?
- Chart.js How to change y axis title position
- How to start the line graph from the left Y axis in a line/bar mixed chart (Chart.js)?
- How to change Chart.js horizontal bar chart Width?
- How to change z-index of chart js tooltip?
- How do I add time sourced from an external source as an X axis to a ChartJS graph?
- Change Axis Line color in Chart created using chart.js
- Chartjs 3.x - How to duplicate X axis on both sides of horizontal bar chart with only 1 dataset?
- How to change the label and grid line position on a timeseries chart in Chart.js 3?
- How to Remove axis Lines from chart in chart js
- How to change color of column in chart js
- How change chart height in chart.js
- angular-chart.js doughnut chart : How do I change width of the arc of a doughnut?
- how to minimize x axis labels to day hours in chart js
- how to label axis within radar chart with chart.js
- How to change fonts and axis labels for Chart.js image rendering with QuickChart?
- chart.js: How do I make the radar chart axis labels bigger?
- How to change axis font in PrimeFaces and Chart.js
- How to change the chart line or area colors according to the user need?
- How to stop axis label from being cut off in chart JS?
- How to change background color of labels in line chart from chart.js?
- How to change default label of each bubble in bubble chart using chartjs-plugin-datalabels
- How to change font weight of footer in tooltips in Chart JS
- How to change chart.js axis labels color?
More Query from same tag
- Creating multiple charts and selecting them later
- How to colorize individual rings in polar chart background in chart.js/ng2-charts?
- Numeric X axis for linechart
- How to include many datapoints to plot in chart.js
- Charts.js not using the right colors
- CharJS : Is it possible to display stacked bar chart with positive scale on both sides of 0 index
- Chartjs bar min, max and avarage value
- Chart.js HTML custom legend issues with doughnut chart
- How to get ChartJs object from dynamically created chart
- Django - update dictionary with missing date values, set to 0
- Chartjs is graphing my values at positions 0,1,2 rather than their values along the x axis
- How to set the gap between data items in a chartjs chart
- Chart JS Custom Labels don't work
- Chart.js doesn't animate on first load
- chart.js LIne Graphs: Fill area above line as opposed to below and to the right
- How can I achieve displaying data points on chart but Dotted? Chart.js V3.7.0
- Syntax Error: Token '{' invalid key at column 2 of the expression [{{id}}] starting at [{id}}]?
- Move y-Axis and hide in Chart.JS V3
- chart.js chart failing to render
- Angular Chart.js not displaying Chart (Legend is Displaying)
- Chart js Bar Time Chart
- Chart.js xAxis linear scale : strange behavior
- chartjs radar glowing edges effect
- Chart JS not displaying graph
- Charts.js: changing xAxis time attribute with function
- Want to show the dataset labels
- Angular-chart copied from example not showing up
- Chartjs Exporting ImageExports Empty Dark Image
- Receiving json data from a server to display a chart.js graph not working
- How can i display multiple years of data from 1 project in Chart.js?