Skip to content

Commit fa8e613

Browse files
author
Ben Taylor
authored
Merge pull request #9 from kahyoung/master
fix: can now conditionally render children
2 parents f9cb1a8 + c90233f commit fa8e613

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/core/JSONLDAbstractNode.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ class JSONLDAbstractNode extends React.Component {
1111
};
1212

1313
getChildJSON(child, isCollection) {
14+
if(!child) return '';
15+
1416
const ChildClass = child.type;
1517
let { children, type, id, parentID, ...schema } = child.props;
1618
if (!!parentID) schema = {'@id': parentID };

0 commit comments

Comments
 (0)