Elective Chaining in Javascript

Shyam1806 - May 22 - - Dev Community

Elective Chaining
Chaining ?
. is used to check properties before ?. if it's **null or **undefined then it returns undefined otherwise its returns the value.

Developers have a lot of work and projects to complete before a time. Source code has large objects, nested loops, containers, for that to check the property.

Let's see the example:

Image description

. . . . . . . . . .