Awakening Awakening - 29 days ago 19
JSON Question

markdown list-styled tree to json

How to parse markdown list-styled tree to json

eg: in

.md


tree1
- tree2(http://xxxx)
- tree2(http://xxxx)
- tree3(http://xxxx)
another-tree1


what I want is to be parsed like json:

[{
name: 'tree1',
link: '',
children: [{...}]
}]

Answer

md-list-tree-parser

parse list-styled markdown tree to json