Webix Event Handler not working after dynamic Element creation

Hi.
find snippet here:
https://snippet.webix.com/q5lrmy32

I have a button, on click it does add a new button from a JS Object to a form.
That works, but the defined Eventhandler in the added component isn´t working.

Any idea ?

Hey @ChristianNRW, this is happening because of the way the JSON.stringify works, by default, it will ignore all methods while parsing and it will encode the values that JSON supports, for instance, you can see this in the example: https://snippet.webix.com/kp8hr4v3 - everything except our function got parsed. Now, it seems that you can override the default behaviour https://stackoverflow.com/a/18089155, but it doesn’t really sound all that promising, so I would advise you to look toward some other method.
I’m not sure about your use-case, but why not just simply do something like this: https://snippet.webix.com/3bpepvy3?

Your last snippet does the trick.
Thank you Dzmitry