Echo JS 0.11.0


ben 579 days ago. link 2 points
Love this. But I noticed the Lodash dependency is pinned. Would it be possible to loosen it a little, to allow for flattened dependencies in frontend bundles?
nickjohnson-dev 579 days ago. link 2 points
Oh yeah, I thought I already fixed that. I just patched it in v3.0.2. Let me know if that change loosens things up enough for you.
xat 580 days ago. link 2 points
Thanks for open sourcing your library. Mostly I write tree-helper functions on a project base, but would definitly be open to try this library next time.

Just skimmed through the code, here are some ideas/suggestions:

- You already have this on your TODO, but being able to use other property-names besides 'children', 'id' etc. would be cool. For example, often the term 'items' is used instead of 'children'.

- Often I need to have additional information about the node in the iterate function. For example, it could be quite useful to have access to the parentNode, the siblings or know the current depth.

- Since this is more like a small helper library, developers will look at the bundle size in order to decide if it's worth pulling this into a frontend project. You could reduce the size by not using lodash for example. I also don't think it's really necessary to have baked in currying, developers can add that, if they need it.
nickjohnson-dev 580 days ago. link 1 point
Thanks for the feedback! I will definitely look into making those improvements.

I have thought about the bundle size, and plan to take a look at slimming it down in the future.

Hadn't considered including the metadata like depth and parent. Great idea! I'll definitely work on adding those features as soon as I get a chance.