# ChartJS manipulation

**URL:** <https://community.weweb.io/t/chartjs-manipulation/2038>\
**Category:** Ask us anything\
**Tags:** chart\
**Created:** [March 14, 2023, 10:28pm UTC](https://community.weweb.io/t/chartjs-manipulation/2038 "2023-03-14T22:28:16Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![chadsmithclt](https://avatars.discourse-cdn.com/v4/letter/c/8797f3/32.png) [@chadsmithclt](https://community.weweb.io/u/chadsmithclt)\
**Post date:** [March 14, 2023, 10:28pm UTC](https://community.weweb.io/t/chartjs-manipulation/2038/1 "2023-03-14T22:28:16Z")

</div>

Hi all, does anyone know of a way to hide the labels for the charts extension?

---

<div class="post-metadata">

**Author:** ![Alexis](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/alexis/32/13248_2.png) [@Alexis](https://community.weweb.io/u/Alexis)\
**Post date:** [March 15, 2023, 1:51pm UTC](https://community.weweb.io/t/chartjs-manipulation/2038/2 "2023-03-15T13:51:00Z")

</div>

Hi, if you’re talking about the legend, it depend of the mode you’re using.

Guided mode =\> Turn off the legend on the style tab

 ![Capture d’écran 2023-03-15 à 14.37.18](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/c/c3419ea57b68f10051f43b465a79bcd91ce892e4.png)

Advanced mode =\> Bind an object to the options property with `{plugins: {legend: false}}`

 ![Capture d’écran 2023-03-15 à 14.38.18](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/9/96aaab1037b68e5f281ccaaecfad6c227d25e5ab.png)

If you’re talking about the labels on the x or y axis for example, I guess you can only do it if you’re using the advanced mode with the options property =\> Bind an object to the options property with `{ scales: {y: {ticks: {display: false}}}}`

 ![Capture d’écran 2023-03-15 à 14.49.04](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/a/a8aef230428053a452fd43bedf50539ab7e5ef26.jpeg)

More options are available, [see the chartjs documentation](https://www.chartjs.org/docs/latest/axes/styling.html#styling).

---

<div class="post-metadata">

**Author:** ![chadsmithclt](https://avatars.discourse-cdn.com/v4/letter/c/8797f3/32.png) [@chadsmithclt](https://community.weweb.io/u/chadsmithclt)\
**Post date:** [March 15, 2023, 2:23pm UTC](https://community.weweb.io/t/chartjs-manipulation/2038/3 "2023-03-15T14:23:55Z")

</div>

Thank you Alexis!! this worked great for one axis but getting errors with multiple axis or adding the legend … for example {scales:{x:{ticks:{display: false}}}{y:{ticks:{display: false}}}}

---

<div class="post-metadata">

**Author:** ![Alexis](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/alexis/32/13248_2.png) [@Alexis](https://community.weweb.io/u/Alexis)\
**Post date:** [March 15, 2023, 5:12pm UTC](https://community.weweb.io/t/chartjs-manipulation/2038/4 "2023-03-15T17:12:23Z")

</div>

I think its just a mistypo, here a correct version =\>

```js
{ scales: { x: { ticks: { display: false } }, y: { ticks: { display: false } } } }

```

x and y must be under the same node, separated by a comma 🙂

---

<div class="post-metadata">

**Author:** ![chadsmithclt](https://avatars.discourse-cdn.com/v4/letter/c/8797f3/32.png) [@chadsmithclt](https://community.weweb.io/u/chadsmithclt)\
**Post date:** [March 16, 2023, 7:43pm UTC](https://community.weweb.io/t/chartjs-manipulation/2038/5 "2023-03-16T19:43:20Z")

</div>

![Screen Shot 2023-03-16 at 3.43.04 PM](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/8/813a57d05cf7ef81ab31c7010ecc7673d8139486.png)

---

<div class="post-metadata">

**Author:** ![Alexis](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/alexis/32/13248_2.png) [@Alexis](https://community.weweb.io/u/Alexis)\
**Post date:** [March 17, 2023, 2:17pm UTC](https://community.weweb.io/t/chartjs-manipulation/2038/6 "2023-03-17T14:17:09Z")

</div>

A } is missing at the end, idk why its hidden in my previous message

 ![Capture d’écran 2023-03-17 à 15.15.42](https://us1.discourse-cdn.com/flex016/uploads/weweb/original/2X/c/c4a8d2ec5097bd84db8a4b0b034c6bf07f459ad9.png)

Edit : Ah, its because its too long so its adding an horizontal scroll sry
