From 94c8cceb42e20e5ab8a8173c7f37fc07f18f2bcf Mon Sep 17 00:00:00 2001 From: Jaco Greeff Date: Thu, 20 Apr 2017 10:41:06 +0200 Subject: [PATCH] Add @parity/jsonrpc --- js/package.json | 1 + js/src/api/api.spec.js | 4 ++-- js/src/api/package.json | 1 + js/src/jsonrpc/package.json | 27 +++++++++++++++++++++++++++ js/webpack/app.js | 2 +- js/webpack/libraries.js | 2 +- 6 files changed, 33 insertions(+), 4 deletions(-) create mode 100644 js/src/jsonrpc/package.json diff --git a/js/package.json b/js/package.json index 64d2a24cf..924191ee3 100644 --- a/js/package.json +++ b/js/package.json @@ -160,6 +160,7 @@ "dependencies": { "@parity/abi": "file:src/abi", "@parity/api": "file:src/api", + "@parity/jsonrpc": "file:src/jsonrpc", "@parity/wordlist": "1.0.1", "base32.js": "0.1.0", "bignumber.js": "3.0.1", diff --git a/js/src/api/api.spec.js b/js/src/api/api.spec.js index 1c5ebf514..aa18333a0 100644 --- a/js/src/api/api.spec.js +++ b/js/src/api/api.spec.js @@ -14,13 +14,13 @@ // You should have received a copy of the GNU General Public License // along with Parity. If not, see . +import ethereumRpc from '@parity/jsonrpc'; + import { TEST_HTTP_URL, endpointTest } from '../../test/mockRpc'; import util from './util'; import Api from './api'; -import ethereumRpc from '../jsonrpc/'; - describe('api/Api', () => { describe('constructor', () => { it('requires defined/non-null transport object', () => { diff --git a/js/src/api/package.json b/js/src/api/package.json index acbd37001..f544ffe4f 100644 --- a/js/src/api/package.json +++ b/js/src/api/package.json @@ -26,6 +26,7 @@ }, "dependencies": { "@parity/abi": "file:../abi", + "@parity/jsonrpc": "file:../jsonrpc", "bignumber.js": "~2.3.0", "eventemitter3": "2.0.2", "js-sha3": "~0.5.2", diff --git a/js/src/jsonrpc/package.json b/js/src/jsonrpc/package.json new file mode 100644 index 000000000..d148126c0 --- /dev/null +++ b/js/src/jsonrpc/package.json @@ -0,0 +1,27 @@ +{ + "name": "@parity/jsonrpc", + "description": "JSON and JS interface defintions for RPC", + "version": "0.0.0", + "main": "index.js", + "author": "Parity Team ", + "maintainers": [ + "Jaco Greeff" + ], + "contributors": [], + "license": "GPL-3.0", + "repository": { + "type": "git", + "url": "git+https://github.com/paritytech/parity.git" + }, + "keywords": [ + "Ethereum", + "RPC", + "Parity" + ], + "scripts": { + }, + "devDependencies": { + }, + "dependencies": { + } +} diff --git a/js/webpack/app.js b/js/webpack/app.js index 6d61f7518..e849ad825 100644 --- a/js/webpack/app.js +++ b/js/webpack/app.js @@ -68,7 +68,7 @@ module.exports = { // duplicated for clarity since the number of @parity modules will increase { test: /\.js$/, - include: /node_modules\/@parity\/(abi|api|wordlist)/, + include: /node_modules\/@parity\/(abi|api|jsonrpc|wordlist)/, use: 'babel-loader' }, { diff --git a/js/webpack/libraries.js b/js/webpack/libraries.js index ff41132be..0c151b828 100644 --- a/js/webpack/libraries.js +++ b/js/webpack/libraries.js @@ -61,7 +61,7 @@ module.exports = { // duplicated for clarity since the number of @parity modules will increase { test: /\.js$/, - include: /node_modules\/@parity\/(abi|api|wordlist)/, + include: /node_modules\/@parity\/(abi|api|jsonrpc|wordlist)/, use: 'babel-loader' }, {