I created some custom control and render a json of form attributes using the component factory and view resolver.
Same approach as below. Query.Add instead of Dynamic Component Loader (loadintolocation)
In custom controls I am emitting a valueChanged
event. The problem is that the viewcomponent
ref always points to the last control that was rendered.
so in this.valueChanged.emit(event)
code , "this" points to the last rendered control though the event emitted is of the control that has been changed.
How to overcome this ?