What does global context mean?
ghuser opened this issue · 3 comments
ghuser commented
I would expect that this loader executes script myScript.js
as if it was included with <script src="myScript.js">
. This is not the case.
The following statement var myVar = {}
will not add myVar as global (in contrast to how <script src="myScript.js">
behaves) . So in the html page: console.log(myVar)
will print undefined.
alexander-akait commented
@ghuser var foo = "bar"; function () { console.log(var); }
inside myScript.js
enriquez commented
FilippoPolo commented
If it is due to "use strict", the version that's currently on master should work. However, there's no release yet.