This survey closed on January 1, 2021. View Survey Results »

Return first value, or second value if first value is null or undefined.

js
const foo = null ?? 'default string';
console.log(foo);
// expected output: "default string"

const baz = 0 ?? 42;
console.log(baz);
// expected output: 0

Properties that cannot be legally referenced outside of the class.

js
class ClassWithPrivateField {
  #privateField
}