from
getFillColor: d => [0, 0, 255], // Adjust the fill color as needed
we can see that DeckGL is expecting color as an array of numbers
but the color scale gives us an rgb value like below.
thus i made a wrapper around colorScale and called it getColor
you can see what's it doing by building it up step by step with each operation after a dot
the last bit converts each value of an array from text to number (using a unary + operation trick)
https://www.reddit.com/r/webdev/comments/88kuxk/the_unary_operator_is_a_shortcut_to_convert_a/
Food Insecurity county columns | 🪦 dis-2024-spring | Observable