tweag / nixpkgs-graph-explorer

Explore the nixpkgs dependency graph
MIT License
15 stars 0 forks source link

Add navigation to search component #79

Closed jlesquembre closed 1 year ago

jlesquembre commented 1 year ago

Closes #30

Screenshot: localhost_5173_

The logic was getting hard to follow. To help with it, I'm using a new dependency, xstate. An additional benefit is that we can visualize the state machine:

stately ai_viz_6cbc5e6c-5f62-4c89-b553-508f2f0c40c0

https://stately.ai/viz/6cbc5e6c-5f62-4c89-b553-508f2f0c40c0

dorranh commented 1 year ago

Wow, this looks great! TIL about xstate - it seems super useful.

jlesquembre commented 1 year ago

It was a bit complex at first to get into the code as things are referenced by string, but once I got the gist it was fairly clear.

Agree, that's something to improve on xstate. You can use values instead of string, which I usually prefer, but in that case, copy/pasting the machine schema in the visualizer doesn't always work.

GuillaumeDesforges commented 1 year ago

@jlesquembre is there a blocker on the merge?