3 ms·
Seems like the logical way to do it. Though, honestly, unless you specifically need to do lots of different kinds of padding, something like this makes way more
by chaorace 3y ago
Seems like the logical way to do it. Though, honestly, unless you specifically need to do lots of different kinds of padding, something like this makes way more sense:
const bespokePad = (x) => ('000000' + x).slice(-6)