Skip to content

Conversation

vivian-perez
Copy link
Member

custom event onLineClicked
dynamic data in TreeNode attributes with TreeView.treeNodeAttributes propType.
TreeView.data propType correction
_this deprecated and replaced with bind

Add "key" for efficient react comparison.
Add an onLineClicked custum event.
Allow developper to pass dynamic information in TreeNode.
Dynamic attributes are passed in an object {attribute key : attribute value }
attribute key: what we want => data-test
attribute value: a key of this.props.data => id

For example,
var data = [
    {
        text: 'Parent 1',
        id: '1',
      }
];

React.render(
    <TreeView
        data={data}
        treeNodeAttributes={{'data-id':'id'}}/>,
    document.getElementById('treeview')
);
vivian-perez added a commit that referenced this pull request Apr 16, 2015
Merge clickByProps branch into master
@vivian-perez vivian-perez merged commit 25d1968 into master Apr 16, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant