You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey, maybe this is a silly question, but I’m trying to add weights to my edges in DagreJS according to the wiki documentation, which states:
“The weight to assign edges. Higher weight edges are generally made shorter and straighter than lower weight edges.”
However, I don’t see any effect on the layout. I have multiple parallel threads with different weights, but changing these values doesn’t affect their relative order or geometry in any noticeable way.
Example
I have a small demo here on JSFiddle. The graph has five parallel “threads” going from a single “start” node to an “end” node, each with different weight values for the edges.
My expectation is that the “heaviest” route (A5) might be placed in the center or otherwise distinguished from lighter routes, but this isn’t happening.
Question
Are edge weights currently expected to influence layout ordering or path shape in DagreJS?
Is there something else I need to configure (e.g., rankdir, ranker, acyclicity, or special layout options) for weights to have an effect?
Is this feature deprecated or only partially supported in the current version of Dagre?
Additional Context
Dagre version: (1.1.4)
Any guidance would be greatly appreciated!
The text was updated successfully, but these errors were encountered:
Hey, maybe this is a silly question, but I’m trying to add weights to my edges in DagreJS according to the wiki documentation, which states:
However, I don’t see any effect on the layout. I have multiple parallel threads with different weights, but changing these values doesn’t affect their relative order or geometry in any noticeable way.
Example
I have a small demo here on JSFiddle. The graph has five parallel “threads” going from a single “start” node to an “end” node, each with different
weight
values for the edges.This is code for defining edges:
My expectation is that the “heaviest” route (A5) might be placed in the center or otherwise distinguished from lighter routes, but this isn’t happening.
Question
Additional Context
Any guidance would be greatly appreciated!
The text was updated successfully, but these errors were encountered: