Optional Chaining in JavaScript

Optional chaining enables capabilities for Javascript developers to perform a nil check on the objects before trying to access any object properties.

As an example:


Optional Chaining behaves similarly to Ruby’s pretzel(&) operator.

Checkout the official babel documentation. Babel - Optional Chaining

What is this Site?

viralpatel.blog is started by me, Viral Patel, as a place to write posts and blogs about problems that I personally face during my day to day and share new learnings about software development work. Even though there is abundant of information out there via various personal blogs or blogs written by technical companies, day in and day out, We as software developers face different problems. By starting out this blog, I wish to explore different problem solving patterns and software design practices that will make easier to build quality and useful software.