The Bang Operator

In this lesson, you will see how the bang operator is used in TypeScript.

Bang operator role

The bang operator is the use of the exclamation point symbol !. The operator can be used after a variable and before the dot to access a member.

It is officially called the “non-null assertion operator”. A variable with the value undefined or null can benefit from using the ...