Is there a method for JavaScript to interpret leading zeros as arguments (with the primitive value as number)? I currently have this code:
let noLeadingZero = (number) => { return number }
console.log('noLeadingZero(00):', noLeadingZero(00)) // 0
console.log('noLeadingZero(000):', noLeadingZero(000)) // 0
console.log('noLeadingZero(0000):', noLeadingZero(0000)) // 0
Is there an alternative way, other than converting the argument to a string when calling the function, to acknowledge the presence of leading zeros?