Depends what you measure ! There are different things that are important for different parts.
speed ? ha ? what is the bottlenet ? what is the target ? what is the metric used ? I'm a slow coder who thinks a lot about his problems so I will always go for quality and efficiency of the functional component.
a company on the other hand will want output so the amount of code written in a certain way will be more important to them.
just pick what you wanna accomplish and choose some metrics like
"memory consumption per iteration", "time complexity" but only for tasks where it matters ;D no one cares if a react component used 22mb of memory :) but if a file read lib used 22mb without reading a file .... this would be weird :)