Beautifully simple way to get a hex value from a number. Note that
d is a number. If you want a string as a hex XML valid code, use:
'&#x' + parseInt(number).toString(16).toUpperCase() + ';'
MY EVENTAttend ffconf.org 2018
The UK's best JS and web development conference. 8 amazing speakers, workshops, socials — find out more & get tickets today.