4 ms·
Show HN: Package Sorter – Sorting a group of packages that depends on each other
- verdverm 6y agohttps://en.wikipedia.org/wiki/Topological_sorting https://en.wikipedia.org/wiki/Topological_sorting is a well known algo for this You could avoid the noDep / coreDep checks by using this
- jimmy2020 6y agoThanks for the feedback. Are you interested in algorithms?
- verdverm 6y agogenerally speaking, yes. I work a lot in DX / dev productivity - https://github.com/verdverm/pypge https://github.com/verdverm/pypge (algo I wrote, works like dijkstra's) - https://github.com/hofstadter-io/cuetorials.com/blob/main/code/examples/algos/toposort.cue https://github.com/hofstadter-io/cuetorials.com/blob/main/co... (I hang around Cue online) - https://github.com/hofstadter-io/hof https://github.com/hofstadter-io/hof (the main thing I work on)
- jimmy2020 6y agoObviously, you are :) considering you take a look at the source code. I have another algorithm for connecting DOM nodes: https://github.com/jalal246/dflex/tree/master/packages/dom-gen https://github.com/jalal246/dflex/tree/master/packages/dom-g...
- verdverm 6y agoI came across dflex on GH some time ago, looking for dnd Dom manip related tools. Small world
- jimmy2020 6y agoI am curious if you liked it or moved to another tool. edit: I know it's still early, but I'm trying to introduce something new beyond `pointer-events` and more into studying each node and its effect on the entire dom tree.
- verdverm 6y agoMoved on, GPL-3 is a non-starter. Working on something with GrapesJS. Are you saying something like "notify" rather than "check for changes" with shadow dom? What is studying -> effect? (in more detail)
- jimmy2020 6y agoWell yes. Thanks. It's exactly "notify" -> click on the node -> node is now ready to move -> function executes desirable effects to all DOM tree based on the movement - It's not framework. You can implement this solution regardless of what you are using. Even async rendering. It doesn't matter how you start rendering. From above to root or otherwise. - This is the only solution, taking into consideration the above pontins, that executes "stream of write requests" to the browser. It doesn't write/read then do it again. No lagging. All manipulation runs smoothly 60fps. - Every change in DOM is registered and updated in the DOM store and exposed. So you can implement (any DOM manipulation) whenever you need in your app.