(num)
| 17 | } |
| 18 | |
| 19 | function decimalToHex(num) { |
| 20 | const hexOut = [] |
| 21 | while (num > 15) { |
| 22 | hexOut.unshift(intToHex(num % 16)) |
| 23 | num = Math.floor(num / 16) |
| 24 | } |
| 25 | return intToHex(num) + hexOut.join('') |
| 26 | } |
| 27 | |
| 28 | export { decimalToHex } |
no test coverage detected