You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ok, so the default in the context is not as necessary. All right, yeah I guess there's not really any real harm in having it, other than that there's an implicit default in the Table and an explicit one in the context.
I think it would be nice to provide defaultProps for our boolean flags. Right now they're implicitly false as not providing them leaves them undefined.
Providing them increases the coding overhead slightly. But reading the code and its intention is easier, it's type-safe (as we'd not be using undefined but false) and doesn't cause confusion when used together with react's context as that one expects a default value
The text was updated successfully, but these errors were encountered:
I think it would be nice to provide
defaultProps
for our boolean flags. Right now they're implicitly false as not providing them leaves themundefined
.Providing them increases the coding overhead slightly. But reading the code and its intention is easier, it's type-safe (as we'd not be using
undefined
butfalse
) and doesn't cause confusion when used together withreact
's context as that one expects a default valueThe text was updated successfully, but these errors were encountered: