Skip to content

Only accept connections from specific node type #887

Answered by bcakmakoglu
FreshLucas-git asked this question in Q&A
Discussion options

You must be logged in to vote

Validation always happens from the source handle, not the target handle, so you have to pass isValidConnection to whatever source handle you're using at the moment.

Alternatively you can just allow the connection and catch it in onConnect and if you're not happy with the potential connection, just don't create a new edge.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@FreshLucas-git
Comment options

@bcakmakoglu
Comment options

Answer selected by FreshLucas-git
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