Hello pals
I have some issue printing the value of an array. I have this array:
public loadKinds: LoadKinds[] = [];
where LoadKinds is defined like this:
export class LoadKinds {
id: number;
name: string;
created_at: string;
updated_at: string;
checked: boolean;
}
I have a slice for showing info and on the page 3 I show that array showing if is checked or not. I showed it like this:
¿Qué puede cargar este auto?
{{lk.name}} {{lk.checked}}On my .ts, I load from backend the list of loadKinds for this car Id. Then, I checked as true if the car have this load kind:
for (const lk of this.loadKinds) {
lk.checked = false;
}
for (const clk of this.car.load_kinds) {
for (const lk of this.loadKinds) {
if (lk.id === clk.id) {
lk.checked = true;
break;
}
}
}
I obtain something like this on navigator and another thing on console:

I have not idea what is happen here. I show this on console the slice page change event using a code like this:
for (let index = 0; index < this.loadKinds.length; index++) {
const element = this.loadKinds[index];
console.log(element.name, element.checked);
}
Once we enter to the slice data is already read.
Please, if someone see some issue here or have same problem, let me know how to solve it.