Initialize Form Group Array with Json Data


#1

Hi
it is possible to initialize a form group array with json data?

this is in my constructor:

and the normal json data is no problem but i can not set a for or something like that in the array

this is how my array, json looks like:

is there a Solution?

Thanks,
Daniel


#2

okay got it:


#3

I think directly accessing the controls array is a bad idea. I’ve made many subtle bugs for myself doing that, and now always use get().


#4

Can you please Post a demo Code?


#5

Just replace .controls['options'] with .get('options').