make Web3 (note capital 'w') globally accessible

This commit is contained in:
Michael Bradley, Jr 2018-07-16 17:31:43 -05:00
parent dc50ea864e
commit 207f3ffe93
1 changed files with 1 additions and 0 deletions

View File

@ -374,6 +374,7 @@ class CodeGenerator {
let providerCode = self.generateProvider(false); let providerCode = self.generateProvider(false);
code += providerCode; code += providerCode;
code += "\nglobal.__embarkContext = __mainContext.__loadManagerInstance;\n"; code += "\nglobal.__embarkContext = __mainContext.__loadManagerInstance;\n";
code += "\nwindow.Web3 = Web3;\n";
code += "\nwindow.web3 = web3;\n"; code += "\nwindow.web3 = web3;\n";
code += "\nexport default web3;\n"; code += "\nexport default web3;\n";
next(null, code); next(null, code);