KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

Hide gridlines in chartjs #3259

Open Melina Maccio opened this topic on on Mar 7 - 3 comments

Melina Maccio commented on Mar 7

Hi! how do I hide the gridines on the chartJs barchart?

John commented on Mar 9

Hi, my suggestion is to try this:

'options' => [

 'scales' => [
  'y' => [
    'grid' => [
       'drawOnChartArea' => false // try also 'display' => false
     ]
  ],
Melina Maccio commented on Mar 11

None of those worked. I'm using chartjs in the dashboard framework by the way.

Sebastian Morales commented on Mar 14

Pls try the following option:

"options" => [
    "scales" => [
        "xAxes" => [
            [
                "gridLines" => [
                    "display" => false
                ]
            ]
        ],
        "yAxes" => [
            [
                "gridLines" => [
                    "display" => false
                ]   
            ]
        ]
    ]
] 

Pls note the xAxes and yAxes are arrays of arrays because there could be multiple x or y axes.

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
help needed

Dashboard