I have been working on a web project in the last 4 months. To optimize code performance, we used a template. I doubt if this really improves performance or not?
when we need to use an object this, we assign it to a local variable and use it.
function someFunction()
{
var thisObject = this;
}
Assuming that assigning an object to a thislocal stack variable improves performance.
I have not seen this type of encoding, so I doubt that it is useless.
EDIT: I know that assigning this object to a local variable is done to save the object, but this is not our case.
source
share