Default min interval for single values #840
Labels
:data
Data/series/scales related issue
enhancement
New feature or request
:xy
Bar/Line/Area chart related
Is your feature request related to a problem? Please describe.
Yes, when using a histogram chart with a single bar and custom
xDomain
(settingmin
and/ormax
). The single bar is not displayed because we cannot compute a sensible interval.Related to #836 & #1184
See https://codesandbox.io/s/flamboyant-tdd-b0hzt?file=/src/App.tsx
Describe the solution you'd like
A fallback
minInterval
of say1/16
or1/20
of the domain should be used to at least render the single value.There should also be a development warning to indicate that we are shooting in the dark trying to set a practical interval based on the data and domain provided, and that the consumer should provide a value.
Describe alternatives you've considered
Set the
minInterval
whenever there is a single value.The text was updated successfully, but these errors were encountered: