stacks icon indicating copy to clipboard operation
stacks copied to clipboard

`resolveResponsiveProp` can be undefined?

Open oliverdolgener opened this issue 1 year ago • 0 comments

Hey man, thanks again for this amazing lib. We're using it for quite some time now and it works really well. There is one thing though that I was wondering:

Why can the output of resolveResponsiveProp be undefined? From your code it seems that it always provides a default. We're using it with Typescript and that forces us to always write something like that:

const columns = resolveResponsiveProp([2, 3, 4]) || 2;

It's not a big deal but can lead to errors over time. I wish I could just leave the fallback out :)

oliverdolgener avatar Jul 21 '23 14:07 oliverdolgener