const response = {
settings: {
nullValue: null,
height: 800,
carNum: 0,
headerText: '',
showSplashScreen: false
}
};
const undefinedValue = response.settings.undefinedValue ?? 'some other default'; // result: 'some other default'
const headerText = response.settings.headerText ?? 'Hello, world!'; // result: ''
const animationDuration = response.settings.carNum?? 300; // result: 0
const showSplashScreen = response.settings.showSplashScreen ?? true; // result: false