Fix shadowing issue on UMD format (#499)

master
Futago-za Ryuu 7 years ago
parent cd02806c94
commit ea688abd02

@ -1539,6 +1539,7 @@ function generateJS( ast, options ) {
const requires = dependencyIds
.map( id => `require("${ js.stringEscape( id ) }")` )
.join( ", " );
const args = dependencyVars.map( v => "root." + v ).join( ", " );
const params = dependencyVars.join( ", " );
parts.push( [
@ -1554,7 +1555,7 @@ function generateJS( ast, options ) {
parts.push( [
" } else {",
" root." + options.exportVar + " = factory();"
" root." + options.exportVar + " = factory(" + args + ");"
].join( "\n" ) );
}

Loading…
Cancel
Save