react
react copied to clipboard
debugging feature: output dependency graph
it would help debugging the logic of a react program to be able to see the full dependency graph in some way. especially if signals/events are created dynamically. for instance one could think of creating a DOT file by walking the dependencies, where the nodes would be labeled by variable name and signal/event type. this could then be visualized nicely by available tools.
i'm not sure this is easy to do since at runtime not all of the required information may be available? just a suggestion - feel free to close.
There is definitively room for improvement on that point.
E.g. I use this branch when I need to debug react itself. Note that OCaml 4.02 added very useful debugging variables that I'm sure can be used with S.trace
to improve the situation a bit. Though that won't give you a clear view of the dependency graph.