code: function colorString(value) {
    const asColor = color(value);
    const r = asColor.r.toString(16);
    const g = asColor.g.toString(16);
    const b = asColor.b.toString(16);
  
    return `#${r.length === 1 ? '0' : ''}${r}${g.length === 1 ? '0' : ''}${g}${b.length === 1 ? '0' : ''}${b}`;
  }
docs: Get a color as #rrggbb for input type='color'