Skip to content

Change default fallbackRouter for manhattan #2851

Closed Answered by kumilingus
trufak asked this question in Q&A
Discussion options

You must be logged in to vote

Yes.

You can introduce a new router or override the default manhattan router:

new joint.dia.Paper({
   /* ... */
   routerNamespace: {
       ...joint.routers,
       manhattan: (vertices, userOpt, linkView) => {
           const opt = { fallbackRouter: joint.routers.rightAngle, ...userOpt };
           return joint.routers.manhattan(vertices, opt, linkView);
       }
   }
});

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by trufak
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants