Search code examples
angularperformanceangular-componentssafe-navigation-operator

Safe navigation operator in angular .ts file


Can we use safe navigation operator in .ts file angular application?
Does it cause any performance related issues if we include in .ts file?


Solution

  • The Optional Chaining operator is part of TypeScript since TypeScript version 3.7 from November 2019 (three years ago). So as long as your TypeScript compiler runs 3.7 or newer, there should be no problem at all using this operator.