AntonioGraca
Posts: 3
Joined: Thu Aug 20, 2020 11:48 pm

Changing class in element grid

Hi

Im trying change a class of an element Grid, runing inside a function the following code.

document.getElementById('Micro_tr').changeClass="corrigir_fixar_header";

in CSS

.corrigir_fixar_header {
margin:auto;
margin-top: 120px;
}

But, nothing change. What I need to do to work?

Ionic 3

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

Re: Changing class in element grid

Hello Antonio,

Please use the attribute ngClass to make the class dynamic for Ionic 3 projects: https://stackoverflow.com/questions/501 ... ss-ngclass

Return to “Issues”