Chart.js icon indicating copy to clipboard operation
Chart.js copied to clipboard

Docs: Tweak up pie/polar/donut chart legend description

Open richb-hanover opened this issue 2 years ago • 1 comments

Documentation Is:

  • [ ] Missing or needed?
  • [X] Confusing
  • [ ] Not sure?

Please Explain in Detail...

In the Legend Configuration Options, it says,

WARNING

The doughnut, pie, and polar area charts override the legend defaults. To change the overrides for those chart types, the options are defined in Chart.overrides[type].plugins.legend.

As a newcomer to Chart.js, this page doesn't tell me quite what I need to use the info.

Your Proposal for Changes

My recommendations:

  1. Move the WARNING below the table of options. Perhaps add this sentence to the intro paragraph: "Warning: for donut, pie,and polar charts, see the Warning below."
  2. More importantly, in the Warning block, expand the example to say, "... the options are defined in Chart.overrides[type].plugins.legend where type can be one of pie (or "pie"), etc.

Many thanks!

Example

No response

richb-hanover avatar Oct 13 '23 20:10 richb-hanover

In addition, many more examples should be added to the documentation. It is unclear overrides should lool like.

rolandort avatar Mar 17 '25 15:03 rolandort