Closed TiuSh closed 5 years ago
If somebody can make the test suite pass with strictNullChecks: false
I'll gladly merge this. Until then I'd like to refer to the docs that document this requirement: https://material-ui.com/guides/typescript/#typescript
Current Behavior 😯
While updating Typescript to the latest version (3.6.3) I had this code failing where it worked with TS 3.3:
After a little investigation I found that it was related to
IsEmptyInterface
from@material-ui/types
that was not working as expected with TS option"strictNullChecks": false
:Expected Behavior 🤔
IsEmptyInterface<{}>
should returntrue
, even when"strictNullChecks": false
.Steps to Reproduce 🕹
Steps:
ShouldBeTrue
is of typetrue
andShouldBeFalse
is of typefalse
ShouldBeTrue
is of typefalse
andShouldBeFalse
is of typetrue
Context 🔦
Actually, I'm not sure if it's an issue from Material-UI or typescript as I don't fully understand the meaning of the type:
https://github.com/mui-org/material-ui/blob/514319e995cd86e39a5eb937afb5923509d4a07a/packages/material-ui-types/index.d.ts#L75L89
Your Environment 🌎