All command available in backend tab console
This commit is contained in:
parent
a622e6c4bb
commit
4eed27a55a
|
@ -1,4 +1,5 @@
|
|||
let utils = require('../../lib/utils/utils.js');
|
||||
const utils = require('../../lib/utils/utils.js');
|
||||
const stringify = require('json-stringify-safe');
|
||||
|
||||
class Console {
|
||||
constructor(options) {
|
||||
|
@ -18,7 +19,7 @@ class Console {
|
|||
let plugin = this.plugins.createPlugin('consoleApi', {});
|
||||
plugin.registerAPICall('post', '/embark-api/command', (req, res) => {
|
||||
this.executeCmd(req.body.command, (_err, result) => {
|
||||
res.send({result});
|
||||
res.send({result: stringify(result, null, 2)});
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
@ -3970,7 +3970,8 @@
|
|||
},
|
||||
"code-point-at": {
|
||||
"version": "1.1.0",
|
||||
"bundled": true
|
||||
"bundled": true,
|
||||
"optional": true
|
||||
},
|
||||
"concat-map": {
|
||||
"version": "0.0.1",
|
||||
|
@ -3979,7 +3980,8 @@
|
|||
},
|
||||
"console-control-strings": {
|
||||
"version": "1.1.0",
|
||||
"bundled": true
|
||||
"bundled": true,
|
||||
"optional": true
|
||||
},
|
||||
"core-util-is": {
|
||||
"version": "1.0.2",
|
||||
|
@ -4082,7 +4084,8 @@
|
|||
},
|
||||
"inherits": {
|
||||
"version": "2.0.3",
|
||||
"bundled": true
|
||||
"bundled": true,
|
||||
"optional": true
|
||||
},
|
||||
"ini": {
|
||||
"version": "1.3.5",
|
||||
|
@ -4092,6 +4095,7 @@
|
|||
"is-fullwidth-code-point": {
|
||||
"version": "1.0.0",
|
||||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"number-is-nan": "^1.0.0"
|
||||
}
|
||||
|
@ -4111,11 +4115,13 @@
|
|||
},
|
||||
"minimist": {
|
||||
"version": "0.0.8",
|
||||
"bundled": true
|
||||
"bundled": true,
|
||||
"optional": true
|
||||
},
|
||||
"minipass": {
|
||||
"version": "2.2.4",
|
||||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"safe-buffer": "^5.1.1",
|
||||
"yallist": "^3.0.0"
|
||||
|
@ -4132,6 +4138,7 @@
|
|||
"mkdirp": {
|
||||
"version": "0.5.1",
|
||||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"minimist": "0.0.8"
|
||||
}
|
||||
|
@ -4204,7 +4211,8 @@
|
|||
},
|
||||
"number-is-nan": {
|
||||
"version": "1.0.1",
|
||||
"bundled": true
|
||||
"bundled": true,
|
||||
"optional": true
|
||||
},
|
||||
"object-assign": {
|
||||
"version": "4.1.1",
|
||||
|
@ -4214,6 +4222,7 @@
|
|||
"once": {
|
||||
"version": "1.4.0",
|
||||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"wrappy": "1"
|
||||
}
|
||||
|
@ -4319,6 +4328,7 @@
|
|||
"string-width": {
|
||||
"version": "1.0.2",
|
||||
"bundled": true,
|
||||
"optional": true,
|
||||
"requires": {
|
||||
"code-point-at": "^1.0.0",
|
||||
"is-fullwidth-code-point": "^1.0.0",
|
||||
|
|
|
@ -62,6 +62,7 @@
|
|||
"i18n": "^0.8.3",
|
||||
"ipfs-api": "17.2.4",
|
||||
"is-valid-domain": "0.0.5",
|
||||
"json-stringify-safe": "^5.0.1",
|
||||
"live-plugin-manager-git-fix": "^0.12.1",
|
||||
"merge": "^1.2.0",
|
||||
"mocha": "^5.2.0",
|
||||
|
@ -107,10 +108,10 @@
|
|||
"homepage": "https://embark.status.im/",
|
||||
"license": "MIT",
|
||||
"devDependencies": {
|
||||
"chai": "4.1.2",
|
||||
"eslint": "4.13.1",
|
||||
"eslint-plugin-react": "^7.10.0",
|
||||
"mocha-sinon": "^1.1.4",
|
||||
"sinon": "^4.5.0",
|
||||
"chai": "4.1.2"
|
||||
"sinon": "^4.5.0"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue