I have no idea why I can't find an answer to this, I feel kinda ridiculous for even asking but it's killing me.
Can function.modifier params be specified via iteration?
let colors = ['red', 'green', 'blue];
Example function uses .modifier(argument) as styling param. (real-world ex: react-toastify)
function alert.red() // red widget
function alert.blue() // blue widget
function alert.green() // green widget
but colors.forEach(color => alert.{color}('arg')) // error
??
.. I mean.. seriously? Am I missing something?