Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/afeiship/next-tree-walk

Tree data walker.
https://github.com/afeiship/next-tree-walk

loop next recursive tree walk

Last synced: 8 days ago
JSON representation

Tree data walker.

Awesome Lists containing this project

README

        

# next-tree-walk
> Tree data walker.

[![version][version-image]][version-url]
[![license][license-image]][license-url]
[![size][size-image]][size-url]
[![download][download-image]][download-url]

## installation
```bash
npm install -S @jswork/next-tree-walk
```

## usage
```js
import '@jswork/next-tree-walk';

class MyComponent extends React.Component{
get childView(){
const { items, itemsKey, template } = this.props;
return nx.treeWalk(items, { template, itemsKey: 'children' });
}

render(){
return (


{this.childView}

)
}
}
```

## license
Code released under [the MIT license](https://github.com/afeiship/next-tree-walk/blob/master/LICENSE.txt).

[version-image]: https://img.shields.io/npm/v/@jswork/next-tree-walk
[version-url]: https://npmjs.org/package/@jswork/next-tree-walk

[license-image]: https://img.shields.io/npm/l/@jswork/next-tree-walk
[license-url]: https://github.com/afeiship/next-tree-walk/blob/master/LICENSE.txt

[size-image]: https://img.shields.io/bundlephobia/minzip/@jswork/next-tree-walk
[size-url]: https://github.com/afeiship/next-tree-walk/blob/master/dist/next-tree-walk.min.js

[download-image]: https://img.shields.io/npm/dm/@jswork/next-tree-walk
[download-url]: https://www.npmjs.com/package/@jswork/next-tree-walk