have about 10 of these customizations for my hue sensors, on several attributes…
icon_color: >
if (state < -5) return 'rgb(30, 255, 255)';
if (state < 0) return 'rgb(30, 144, 255)';
if (state < 10) return 'rgb(255, 255, 0)';
if (state < 15) return 'rgb(255, 211, 30)';
if (state < 20) return 'rgb(0, 128, 0)';
if (state < 25) return 'rgb(255, 165, 0)';
if (state < 30) return 'rgb(255, 0, 0)';
if (state < 35) return 'rgb(85, 0, 0)';
return 'rgb(47, 0, 0)';
guess you can imagine the length of that customize file… wouldn’t it be possible to have a customizations like this written out and name it temperature_customization, and use that for all sensors instead of the full set like above?
This was my first thought too! write it once in secrets and then just use the secret over and over. I believe customize supports secrets as I used to pass a URL this way.