Closed saperdadsk closed 9 months ago
Nice find. Would you be willing to put together a PR that fixes this? (I'm guessing just replacing the ??
with ||
would do it, but you have a way to verify the fix)
@bvaughn Sure - let me try it out
Opened a PR with a fix, though I can't figure out how to write tests for this (Spent way too long trying) - it looks like the JSDOM version in the repo doesn't support empty strings for padding
Been seeing an error periodically when running some tests on our webpage via Cypress:
I don't currently have a consistent reproduction case - error only happens when running in the test environment.
I traced the error down to this library, and specifically https://github.com/bvaughn/react-virtualized-auto-sizer/blob/master/src/AutoSizer.ts#L155-L185, and noticed the comment there referencing an old issue on react-virtualized (https://github.com/bvaughn/react-virtualized/issues/150). It looks like the checks added in https://github.com/bvaughn/react-virtualized/commit/33bdde89dd63983ce2c7b724b5e0ab1ee8c4f726 were modified at some point to use null-coalescing, which no longer handles empty string values.
I'll note we're still running on React 17 and Cypress 10.