Quantcast
Channel: GoJS - Northwoods Software
Viewing all articles
Browse latest Browse all 7069

Is there a way to properly log and inspect data returned from an event?

$
0
0

@hitautodestruct wrote:

I am trying to inspect data returned from a ObjectSingleClicked event.

Specifically I’m trying to understand what I can use from the e.subject parameter to get the exact position of the clicked shape in the Layout.

What I’m getting is a set of data with mostly incomprehensible parameters using this code:

diagram.addDiagramListener('ObjectSingleClicked', e => {
  console.log(e)
})

Something like the following is logged to the console:

> Af {aa: E, Sb: "ObjectSingleClicked", Qw: Y, zw: null, br: false}
KB: (...)
Qw: Y {…}
Sb: "ObjectSingleClicked"
aa: E {…}
br: false
cancel: (...)
diagram: (...)
g: (...)
nB: (...)
name: (...)
parameter: (...)
subject: (...)
zw: null

Is there a way to see the original names of these parameters so I can get a better understanding of what is returned from an event?
There seems to be no description of the events parameters in the API docs.

Thanks

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 7069

Trending Articles