---
title: "Discussion on \"Nullish coalescing operator (??)\" | Hashnode"
description: "Discussion on \"Nullish coalescing operator (??)\". The Nullish coalescing operator(??) is a logical operator that returns the right side operand when its left side operand is null or undefined, otherwise it returns left side operand.\nFor Example:- \nconst foo =  null ?? \"it is foo\";  // output   it is..."
url: "https://hashnode.com/posts/nullish-coalescing-operator/61dd86d444f1964f4fa7ced5"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Nullish coalescing operator (??)](https://my-blogs.hashnode.dev/nullish-coalescing-operator?utm_source=hashnode&utm_medium=feed)

The Nullish coalescing operator(??) is a logical operator that returns the right side operand when its left side operand is null or undefined, otherwise it returns left side operand. For Example:- const foo = null ?? "it is foo"; // output it is...

Jan 11, 2022 · 1 min read · my-blogs.hashnode.dev  
Read the article

## Written by

[deepak goyal](https://hashnode.com/@Deepak8269)

@Deepak8269

  
[View profile](https://hashnode.com/@Deepak8269)

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
