Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(lint/types): fix or ignore remaining lint type errors
- use TS 3.0 defaultProps support so that clearOnResize doesn't have to be optional - ignore consistent-type-assertions and no-non-null-assertion in places where those hacks were intentionally used for simplicity's sake - fix some strict-boolean-expressions by checking for types explicitly or using nullish coalescing - nullish coalescing on canvasProps isn't breaking because it already had PropTypes.object defined - nullish coalescing on DPR isn't breaking because it should be a number (or undefined), and shouldn't be 0 - and even if it were 0, it would've been set to 1 before anyway bc of the Math.max - ignore several strict-boolean-expressions in _resizeCanvas because checking for undefined specifically is a breaking change - 0, '', null, etc falsey width/height was still resized previously, so if we check for undefined instead, it will stop resizing falseys - 0, '', null, etc don't make a lot of sense to set a width/height, if these were used it may have been accidental or for some temporary hack - accidental would be a bug, so will consider a fix, but fixing that bug would still be breaking :/ :/
- Loading branch information