I’ve been going through Medium to get some updates about programming. A couple of articles confused me that were related to “Safe Assignment Operator”:
async function getData() {
const [networkError, res] ?= await fetch('https://api.backend.com/resource/1')
if(networkError) console.error(networkError)
const [parseError, data] ?= await res.json()
if(parseError) console.error(parseError)
return data
}
I tried finding the official documentation on MDN, but nothing found. I also tried on console but no luck.
Is this a myth or isn’t the MDN site updated?