-
Notifications
You must be signed in to change notification settings - Fork 1k
Closed
Labels
bugissue that does not match design or documentation and requires code changes to addressissue that does not match design or documentation and requires code changes to address
Description
Expected Behavior
We have code similar to this (without the explicit false)
<FormField>
<TextInput />
{false && <Text>foobar</Text>}
</FormField>
In v2.35.0 this would render fine with just the TextInput inside the form field
Actual Behavior
In v2.36.0 and v2.36.1 this code results in an error: 'Cannot read properties of null (reading 'props')'
It is failing around this line in FormField:
(child.props?.readOnly === true || |
URL, screen shot, or Codepen exhibiting the issue
https://codesandbox.io/p/sandbox/determined-noyce-yjhfjg?file=%2Fsrc%2FApp.js
Steps to Reproduce
- Have a FormField with a null or false child
Your Environment
- Grommet version: v2.36.0 and v.2.36.1 (verified issue is present in both these versions)
- Browser Name and version: Chrome
- Operating System and version (desktop or mobile): Mac
Metadata
Metadata
Assignees
Labels
bugissue that does not match design or documentation and requires code changes to addressissue that does not match design or documentation and requires code changes to address