Skip to content
Discussion options

You must be logged in to vote

After reading through this libraries code I came across (dragStart) and (dragEnd) from f-flow. After wiring dragStart and logging it I noticed it was emitting events for creating connections. For anyone who comes across this, here is how I solved it.

First off you should note that in order to include meta data with my inputs/outputs, like the type of sockets they are, I just prefixed the Id with <type>|<id>. I don't know if there is an easier way to do this but it's working for now.

In my flow host class I have

dragStarted(event: FDragStartedEvent) {
    if (event.fData && event.fEventType === 'create-connection') {
      this.connectionType = event.fData.fOutputOrOutletId.split('|')[0];
…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@siarheihuzarevich
Comment options

Answer selected by bstaley
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