Require web3 at the correct place (in renderer)

pull/1/head
Alex Beregszaszi 9 years ago
parent 7b9e9af51d
commit f08850ddfb
  1. 3
      src/app.js
  2. 4
      src/app/compiler.js
  3. 3
      src/app/renderer.js

@ -1,5 +1,4 @@
var $ = require('jquery');
var web3 = require('./web3-adapter.js');
var utils = require('./app/utils');
var queryParams = require('./app/query-params');
@ -407,7 +406,7 @@ var run = function() {
return $.getJSON('https://api.github.com/repos/' + root + '/contents/' + path, cb);
}
var compiler = new Compiler(web3, editor, handleGithubCall, $('#output'), getHidingRHP, updateFiles);
var compiler = new Compiler(editor, handleGithubCall, $('#output'), getHidingRHP, updateFiles);
function setVersionText(text) {
$('#version').text(text);

@ -4,8 +4,8 @@ var Renderer = require('./renderer');
var Base64 = require('js-base64').Base64;
function Compiler(web3, editor, handleGithubCall, outputField, hidingRHP, updateFiles) {
var renderer = new Renderer(web3, editor, this, updateFiles);
function Compiler(editor, handleGithubCall, outputField, hidingRHP, updateFiles) {
var renderer = new Renderer(editor, this, updateFiles);
var compileJSON;
var compilerAcceptsMultipleFiles;

@ -1,10 +1,11 @@
var $ = require('jquery');
var web3 = require('../web3-adapter.js');
var UniversalDApp = require('../universal-dapp.js');
var utils = require('./utils');
function Renderer(web3, editor, compiler, updateFiles) {
function Renderer(editor, compiler, updateFiles) {
var detailsOpen = {};
var executionContext = 'vm';

Loading…
Cancel
Save