Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/sanichkotikov/relatives-tree

A tiny library for calculating specific JSON data to family tree nodes and connectors 🌳
https://github.com/sanichkotikov/relatives-tree

es6-modules family-tree familytree graph-algorithms no-dependencies npm-module npm-package vanillajs

Last synced: 4 days ago
JSON representation

A tiny library for calculating specific JSON data to family tree nodes and connectors 🌳

Awesome Lists containing this project

README

        

# relatives-tree

A tiny library (~3.23 kB br) for calculating specific JSON data to family tree nodes and connectors.

🖥 [Here is a demo](https://sanichkotikov.github.io/react-family-tree-example/) app with React rendering.

```js
import calcTree from 'relatives-tree';

const tree = calcTree(json, { rootId });
```

The nodes & the connectors are simple JS objects, so you can use any rendering layer.

## Usage

🛠 [Canvas example](/docs)
🛠️ [React example](https://github.com/SanichKotikov/react-family-tree) (react-family-tree source code)
🛠️ [Solid example](https://github.com/SanichKotikov/solid-family-tree-example)

📝 [JSON data examples](/samples).

## Contributing

Please read [this documentation](https://github.com/SanichKotikov/contributing) before contributing.