Skip to content

It's a pure JavaScript framework and it handles large tree types of data. dataTree is used to simple, fast, and lite weight. CRUD (Create, Read, Update, Delete) options available.

License

Notifications You must be signed in to change notification settings

minisuperfiles/DataTree

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DataTree

It's a pure JavaScript framework and it handles large tree types of data. dataTree is used to simple, fast, and lite weight. CRUD (Create, Read, Update, Delete) options available.

Example Code

<script src="DataTree.js"></script>
<link href="DataTree.css">
<div id="datatree"></div>
<script>
var tree= new DataTree(
  document.querySelector('#datatree'),
  {name:'Creatures',d:[
    {name:'Animals',d:[]},
    {name:'Humans',
        d:[{name:'Women',d:[]}, {name:'Men',d:[]}]
    },
    {name:'Brids',d:[]}
  ]}
);
</script>
 
Syntax (parameter)

new DataTree(element)
new DataTree(element,data)
new DataTree(element,data,warning)

data = { name: 'name', d[ { name: 'name', d[{...}] ,...}] }

element

Give DOM element, this element is the target place to create DataTree.

data (Optional)

Give object, It's used to load DataTree content of the data.

warning (Optional)

It's a boolean data type (true or false) and the default value is true. confirm the message control parameter. If the given value is true. when try to delete data confirm popup asking 'Are sure to delete'.

DataTree Methods
DataTree.getData()
It's used to get data of DataTree and its return object.
  • code : tree.getData();
DataTree.render()
It's use to reprint html element.
  • code : tree.render();

View Documentation (Demo)

Learn more about in minisuperfiles.blogspot.com

About

It's a pure JavaScript framework and it handles large tree types of data. dataTree is used to simple, fast, and lite weight. CRUD (Create, Read, Update, Delete) options available.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published