Javascript has a really cool operator called Nullish Coalescing & it can help you out!
It's a logical operator that returns the value of the right side if it is null or undefined
const cars = numberOfCars ?? 'incomplete data'
If the numberOfCars is null we see incomplete data. Like this kind of tech content? Let me know! Thinking about creating a lot more of it. Breakdowns to make concepts easier to digest and understand.
Make sure to share this with someone! Never know who might learn something new!