Unable to remove a text field dynamically from a form

Hello,

I have a modal form in which I dynamically add text fields but also have an option to remove the text fields in case some extra are created. The adding piece of code works fine but removing the text field is not working as expected.
Here is the snippet:
https://webix.com/snippet/8644a450

If you click on “Add Field” it adds nicely a row of input and a button but when you try to remove the field it doesnt work. The piece of code to remove the input field in the following snippet is commented out but if you un-comment it, you will see its not working.

https://webix.com/snippet/8644a450

Hello,
You can use such code when you remove the rows as follows:

click: function() {
var toRemove = this.getParentView();
this.getParentView().getParentView().removeView(toRemove)
}

Here is implementation of your code: https://webix.com/snippet/88333dd4

Oh nice. Thanks a lot. It worked.