Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Difficult debugging on invalid scale.range arguments #267

Open
Stan-Stani opened this issue Sep 8, 2022 · 0 comments
Open

Difficult debugging on invalid scale.range arguments #267

Stan-Stani opened this issue Sep 8, 2022 · 0 comments

Comments

@Stan-Stani
Copy link

I accidentally wrote

yScale.range([height - padding, padding]);
as
yScale.range([height - padding], padding);

No error was thrown and it took me a long time to figure out why my yScale was returning undefined on all inputs.

Could we make scale.range throw an error when more than one argument is present and/or when a scale can't be generated from the given 1st parameter?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant