AfterAdd

fires after adding a shape

void AfterAdd(string|number id){ ... };

Parameters

idstring|numberthe id of a shape which was added

Example

diagram.events.on("AfterAdd", function(id){
    console.log("A new item is added");
});

Related samples

Details

Event can be used to provide default values or a default formatting for the shapes data.

See also
Back to top