diff options
author | Thomas <thomas.b.huang@gmail.com> | 2018-07-11 02:34:00 +0800 |
---|---|---|
committer | Thomas <thomas.b.huang@gmail.com> | 2018-07-11 02:34:00 +0800 |
commit | 5188b727d43e91087449818dee69942c382b6d89 (patch) | |
tree | 4a89be50f09d24bc7e6ed3daf83b660f5e87380e /development/mock-dev.js | |
parent | dd18684a5d682f48528f278284619983f13bf82f (diff) | |
parent | f6de948e42ae633d40aef72595a01caa622a280d (diff) | |
download | tangerine-wallet-browser-5188b727d43e91087449818dee69942c382b6d89.tar tangerine-wallet-browser-5188b727d43e91087449818dee69942c382b6d89.tar.gz tangerine-wallet-browser-5188b727d43e91087449818dee69942c382b6d89.tar.bz2 tangerine-wallet-browser-5188b727d43e91087449818dee69942c382b6d89.tar.lz tangerine-wallet-browser-5188b727d43e91087449818dee69942c382b6d89.tar.xz tangerine-wallet-browser-5188b727d43e91087449818dee69942c382b6d89.tar.zst tangerine-wallet-browser-5188b727d43e91087449818dee69942c382b6d89.zip |
Merge branch 'develop' into removeNonceTrackerFunction
Diffstat (limited to 'development/mock-dev.js')
-rw-r--r-- | development/mock-dev.js | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/development/mock-dev.js b/development/mock-dev.js index f332633d5..15f6ad4bf 100644 --- a/development/mock-dev.js +++ b/development/mock-dev.js @@ -12,7 +12,6 @@ * To use, run `npm run mock`. */ -const extend = require('xtend') const render = require('react-dom').render const h = require('react-hyperscript') const Root = require('../ui/app/root') @@ -24,7 +23,6 @@ const Selector = require('./selector') const MetamaskController = require('../app/scripts/metamask-controller') const firstTimeState = require('../app/scripts/first-time-state') const ExtensionPlatform = require('../app/scripts/platforms/extension') -const extension = require('./mockExtension') const noop = function () {} const log = require('loglevel') @@ -81,14 +79,14 @@ const controller = new MetamaskController({ initState: firstTimeState, }) global.metamaskController = controller -global.platform = new ExtensionPlatform +global.platform = new ExtensionPlatform() // // User Interface // actions._setBackgroundConnection(controller.getApi()) -actions.update = function(stateName) { +actions.update = function (stateName) { selectedView = stateName updateQueryParams(stateName) const newState = states[selectedView] @@ -98,7 +96,7 @@ actions.update = function(stateName) { } } -function modifyBackgroundConnection(backgroundConnectionModifier) { +function modifyBackgroundConnection (backgroundConnectionModifier) { const modifiedBackgroundConnection = Object.assign({}, controller.getApi(), backgroundConnectionModifier) actions._setBackgroundConnection(modifiedBackgroundConnection) } @@ -112,7 +110,7 @@ var store = configureStore(firstState) // start app startApp() -function startApp(){ +function startApp () { const body = document.body const container = document.createElement('div') container.id = 'test-container' |