[Bug]: stepped option is only accepting true

Author: Fabian-AnnaCreated May 27, 2024Updated May 28, 2024
Labelsbug

Would you like to work on a fix?

  • Check this if you would like to implement a PR, we are more than happy to help you go through the process.

Current and expected behavior

When using the stepped option for a dataset, Typescript only allows true | false as a valid value despite showing the valid strings from the documentation as an option.

It should accept the options "before" | "after" | "middle" as valid options as strings.

Reproduction

https://codesandbox.io/p/devbox/compassionate-brahmagupta-npxf8t?file=%2FApp.tsx%3A52%2C16

chart.js version

v4.4.3

react-chartjs-2 version

v5.2.0

Possible solution

No response

Source: reactchartjs/react-chartjs-2