8 lines
162 B
Plaintext
8 lines
162 B
Plaintext
// @flow
|
|
function numberToHex(value: number): string {
|
|
const hex = value.toString(16)
|
|
return hex.length === 1 ? `0${hex}` : hex
|
|
}
|
|
|
|
export default numberToHex
|