Custom render reuses default renderer


Hi guys,

I need to mark executed pass of the flow.
I want to use CustomRender for this purpose.
I want to get default rendered element’s shapes and mark them somehow, for example change color.
How can I get those default shapes and update them at drawShape/drawConnection methods of CustomRenderer?

Thanks a lot


Sorry for waste of topic, I don’t see how I can delete not that smart questions I post.
I found an answer at this example:


There is no need for a custom renderer if you only want to color elements. You can use the existing API to simply set the color. Read more about it here.


Thanks for the response.
I tried this example and it worked for me.
The issue is, that I am using BpmnViewer, not modeler.


Even then it is possible to get around implementing a custom renderer by using more low-level APIs. I’ve done exactly this in bpmn-js-token-simulation in case you’re interested.