I use angular cli 6.
How can i transform this first array to the second array ?
[Array(4)]
0:(2) ["a", "b"]
(2) ["a", "b"]
0:"a"
1:"b"
I try this :
var newArr = [...this.ppssToDisplay.effetsind[0]];
console.log(this.ppssToDisplay.effetsind) ;
console.log(newArr) ;
this.ppsForm.controls['requirements'].setValue(newArr);
I obtain :
console.log(this.ppssToDisplay.effetsind) ;
[Array(1)]
0:Array(1)
0:(2) ["Troubles de la vessie", "Troubles de l'érection"]
length:1
console.log(newarr) ;
[Array(2)]0: Array(2)0: "Troubles de la vessie"1: "Troubles de l'érection"length: 2__proto__: Array(0)length: 1__proto__: Array(0)
But i need this kind of array :
(2) ["a", "b"]
0:"a"
1:"b"