Re:The Cost of JavaScript in 2019
by whatshisface on Sunday June 30, 2019 @03:09PM
(#20319868)
You wouldn't write this in an inner loop, you would do it once in the entire program. It's a literal object that doesn't change.
Also micro performance becomes macro at scale. This is not something that you worry or think about with a handful of literals. It would be good for an inner loop or code generator.