isNonFragmentReactElement
Checks whether x is of type ReactElement, excluding Fragment.
- @param
x- Value to check - @returns
trueifxis aReactElementand not aFragment,falseotherwise.
Example
const value = <div>Hello</div>
isNonFragmentReactElement(value) // true