return this || (0,eval)(‘this’);
It’s getting a reference to the global object, in order to assign doT to it. This is generally done because with a JavaScript library/framework/etc, its one global identifier needs to be exposed to the outside world. As for why it’s not simply window.doT = doT;, it’s because the global object isn’t always window, for example, … Read more