Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

258
Visualizações
Is there a way to catch expression change error?

I'm getting NG0100 error (Expression changed) in my console. Is there any way I can catch this error in my code and print it in the console via my code?

I tried try catch block but it doesn't seem to be working.

try{
//error generating code
}
catch(e){
console.log(e.message)
}

Thanks!

about 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

Actually, catch a NG0100 won't help that much. It's not a blocking error, it's just a big warning to tell yout that your code is unsafe and some expressions change at a point of the component genereation where it shouldn't.

It is supported by Angular DoubleCheck wich is a system that check your template binded attributes to make sure your code is stable and predictable. NG0100 means your expression has changed between these two checks. It is just a warning because this DoubleCheck only exists in devmode (aka ng serve or ng build --configuration developement).

Best you can do is find why and where this happens in your code, to avoid it. The informations given can't let us know, but you can watch this video from Angular official documentation that explains most common reasons of NG0100

about 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda