Skip to content

Can I disable a certain action without using the setInteractive action of useVueFlow? #693

Answered by bcakmakoglu
starter-dev asked this question in Q&A
Discussion options

You must be logged in to vote

Sure, you can use the nodesDraggable option to disable/enable dragging for all nodes at once.

the setInteractive option really just does this:

const setInteractive: Actions['setInteractive'] = (isInteractive) => {
    state.nodesDraggable = isInteractive
    state.nodesConnectable = isInteractive
    state.elementsSelectable = isInteractive
  }

You can set all of these options separately yourself, no need to use the setInteractive action.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@starter-dev
Comment options

Answer selected by starter-dev
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