1
Well, I’m developing an app with Ionic and firebase. Everything is happening as expected, however, when I try to bring the data for editing, the data is all in a column of the list, I did several searches but I did not find a way to tidy up.
method to save information to the vector. TS:
if (this.vetCarrinho.indexOf(element) === -1) {
this.vetCarrinho.push(element);
Html :
<ion-list>
<ion-item *ngFor="let element of vetCarrinho">
{{element}}
<button ion-button color="danger" (click)="deleteProduto(element)" item-end>
<ion-icon name="trash"></ion-icon>
</button>
</ion-item>
</ion-list>
I didn’t understand the: "they all stay in one column of the list"? It wasn’t clear what you want to do or show.
– Cassio Alves
In the list of the app’s screen, it is : Mobile, Mobile. But the correct one would be: column 1: Mobile & #Xa;column 2: Mobile
– user125721
which attributes(columns) you have in the element?
– Cassio Alves
element = this.pedido.product, which would be the product chosen in the ion-select
– user125721
what is the result that appears if you give a console.log(vetCart) ?
– Cassio Alves
exactly like this: [""cell phone ]. With multiple white spaces before and after the element
– user125721
Let’s go continue this discussion in chat.
– Cassio Alves