Como verificar quando um número varibal = nan em ts

if (isNaN(number)) {
      number = 0;
}
Mr Big Code