Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
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 🌳
- Host: GitHub
- URL: https://github.com/sanichkotikov/relatives-tree
- Owner: SanichKotikov
- License: mit
- Created: 2018-12-26T19:36:14.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2024-07-10T19:12:27.000Z (4 months ago)
- Last Synced: 2024-10-24T14:03:28.260Z (27 days ago)
- Topics: es6-modules, family-tree, familytree, graph-algorithms, no-dependencies, npm-module, npm-package, vanillajs
- Language: TypeScript
- Homepage: https://sanichkotikov.github.io/react-family-tree-example/
- Size: 1020 KB
- Stars: 45
- Watchers: 2
- Forks: 21
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
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.