MCPcopy Create free account
hub / github.com/ElemeFE/element-react / getChildren

Method getChildren

src/tree/model/node.js:295–310  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

293 }
294
295 getChildren() { // this is data
296 const data = this.data;
297 if (!data) return null;
298
299 const props = this.store.props;
300 let children = 'children';
301 if (props) {
302 children = props.children || 'children';
303 }
304
305 if (data[children] === undefined) {
306 data[children] = null;
307 }
308
309 return data[children];
310 }
311
312 updateChildren() {
313 const newData = this.getChildren() || [];

Callers 1

updateChildrenMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected