Remove /index imports (swap to bare) (#773)

* Remove /index imports (swap to bare)

* Bump common
This commit is contained in:
Jaco Greeff
2019-03-14 09:02:55 +01:00
committed by GitHub
parent 128e66e4af
commit 34888bd4fb
81 changed files with 117 additions and 108 deletions
@@ -6,7 +6,7 @@ import { Observable, of } from 'rxjs';
import { map, startWith } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { decodeAddress } from '@polkadot/keyring';
import { AccountId, AccountIndex, Address } from '@polkadot/types/index';
import { AccountId, AccountIndex, Address } from '@polkadot/types';
import { isU8a } from '@polkadot/util';
import { idToIndex } from './idToIndex';
@@ -5,7 +5,7 @@
import { Observable } from 'rxjs';
import { map, startWith } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, AccountIndex } from '@polkadot/types/index';
import { AccountId, AccountIndex } from '@polkadot/types';
import { indexes, AccountIndexes } from './indexes';
import { drr } from '../util/drr';
@@ -6,7 +6,7 @@ import { Observable } from 'rxjs';
import { map, startWith } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { ENUMSET_SIZE } from '@polkadot/types/type/AccountIndex';
import { AccountId, AccountIndex, Vector } from '@polkadot/types/index';
import { AccountId, AccountIndex, Vector } from '@polkadot/types';
import { drr } from '../util/drr';
+1 -1
View File
@@ -6,7 +6,7 @@ import { combineLatest, Observable } from 'rxjs';
import { map, switchMap } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { ENUMSET_SIZE } from '@polkadot/types/type/AccountIndex';
import { AccountId, AccountIndex } from '@polkadot/types/index';
import { AccountId, AccountIndex } from '@polkadot/types';
import { drr } from '../util/drr';
@@ -6,7 +6,7 @@ import BN from 'bn.js';
import { combineLatest, Observable } from 'rxjs';
import { map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, AccountIndex, Address, Balance } from '@polkadot/types/index';
import { AccountId, AccountIndex, Address, Balance } from '@polkadot/types';
import { DerivedBalances } from '../types';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import { combineLatest, Observable, of } from 'rxjs';
import { map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, Address } from '@polkadot/types/index';
import { AccountId, Address } from '@polkadot/types';
import { DerivedBalancesMap } from '../types';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import { combineLatest, of, Observable } from 'rxjs';
import { map, switchMap } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, AccountIndex, Address, Balance } from '@polkadot/types/index';
import { AccountId, AccountIndex, Address, Balance } from '@polkadot/types';
import { idAndIndex } from '../accounts/idAndIndex';
import { DerivedBalances } from '../types';
@@ -4,7 +4,7 @@
import { combineLatest, Observable, of } from 'rxjs';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, AccountIndex, Address } from '@polkadot/types/index';
import { AccountId, AccountIndex, Address } from '@polkadot/types';
import { DerivedBalances } from '../types';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import { Observable, of } from 'rxjs';
import { switchMap } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, AccountIndex, Address, Vector } from '@polkadot/types/index';
import { AccountId, AccountIndex, Address, Vector } from '@polkadot/types';
import { idAndIndex } from '../accounts/idAndIndex';
import { DerivedBalances } from '../types';
+1 -1
View File
@@ -5,7 +5,7 @@
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { BlockNumber, Header } from '@polkadot/types/index';
import { BlockNumber, Header } from '@polkadot/types';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import { Observable } from 'rxjs';
import { filter, map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { BlockNumber, Header } from '@polkadot/types/index';
import { BlockNumber, Header } from '@polkadot/types';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import { Observable, combineLatest } from 'rxjs';
import { map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { BlockNumber } from '@polkadot/types/index';
import { BlockNumber } from '@polkadot/types';
import { drr } from '../util/drr';
import { bestNumber } from './bestNumber';
+1 -1
View File
@@ -5,7 +5,7 @@
import { Observable, combineLatest, of } from 'rxjs';
import { catchError, map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { Header, HeaderExtended } from '@polkadot/types/index';
import { Header, HeaderExtended } from '@polkadot/types';
import { drr } from '../util/drr';
import { HeaderAndValidators } from './subscribeNewHead';
@@ -5,7 +5,7 @@
import { Observable, combineLatest, of } from 'rxjs';
import { filter, map, switchMap } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, Header, HeaderExtended } from '@polkadot/types/index';
import { AccountId, Header, HeaderExtended } from '@polkadot/types';
import { drr } from '../util/drr';
@@ -6,7 +6,7 @@ import BN from 'bn.js';
import { Observable } from 'rxjs';
import { map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { Option, ReferendumInfo, ReferendumIndex } from '@polkadot/types/index';
import { Option, ReferendumInfo, ReferendumIndex } from '@polkadot/types';
import { isNull } from '@polkadot/util';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import BN from 'bn.js';
import { combineLatest, Observable, of } from 'rxjs';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { Option } from '@polkadot/types/index';
import { Option } from '@polkadot/types';
import { drr } from '../util/drr';
import { referendumInfo, ReferendumInfoExtended } from './referendumInfo';
@@ -6,7 +6,7 @@ import BN from 'bn.js';
import { combineLatest, Observable, of } from 'rxjs';
import { map, switchMap } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, Balance, Vector, Vote } from '@polkadot/types/index';
import { AccountId, Balance, Vector, Vote } from '@polkadot/types';
import { DerivedReferendumVote } from '../types';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import { combineLatest, Observable, of } from 'rxjs';
import { switchMap } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { Option, ReferendumIndex } from '@polkadot/types/index';
import { Option, ReferendumIndex } from '@polkadot/types';
import { drr } from '../util/drr';
import { ReferendumInfoExtended } from './referendumInfo';
+1 -1
View File
@@ -5,7 +5,7 @@
import BN from 'bn.js';
import { combineLatest, Observable, of } from 'rxjs';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, Vote } from '@polkadot/types/index';
import { AccountId, Vote } from '@polkadot/types';
import { drr } from '../util/drr';
+1 -1
View File
@@ -7,7 +7,7 @@ import ApiRx from '@polkadot/api/rx/Api';
import { ApiInterface$Rx } from '@polkadot/api/types';
import MockProvider from '@polkadot/rpc-provider/mock';
import { Derive } from './index';
import { Derive } from '.';
const testFunction = (api: ApiInterface$Rx) => {
return <
+1 -1
View File
@@ -6,7 +6,7 @@ import BN from 'bn.js';
import { combineLatest, Observable } from 'rxjs';
import { map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { BlockNumber } from '@polkadot/types/index';
import { BlockNumber } from '@polkadot/types';
import { drr } from '../util/drr';
@@ -6,7 +6,7 @@ import BN from 'bn.js';
import { combineLatest, Observable } from 'rxjs';
import { map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { BlockNumber } from '@polkadot/types/index';
import { BlockNumber } from '@polkadot/types';
import { sessionProgress } from './sessionProgress';
import { drr } from '../util/drr';
@@ -6,7 +6,7 @@ import BN from 'bn.js';
import { combineLatest, Observable } from 'rxjs';
import { map } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { BlockNumber, Option } from '@polkadot/types/index';
import { BlockNumber, Option } from '@polkadot/types';
import { bestNumber } from '../chain';
import { drr } from '../util/drr';
@@ -5,7 +5,7 @@
import { Observable } from 'rxjs';
import { switchMap } from 'rxjs/operators';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { AccountId, Vector } from '@polkadot/types/index';
import { AccountId, Vector } from '@polkadot/types';
import { DerivedBalancesMap } from '../types';
import { validatingBalances } from '../balances';
+1 -1
View File
@@ -3,7 +3,7 @@
// of the Apache-2.0 license. See the LICENSE file for details.
import BN from 'bn.js';
import { AccountId, Balance, Vote } from '@polkadot/types/index';
import { AccountId, Balance, Vote } from '@polkadot/types';
export type DerivedBalances = {
accountId: AccountId,
+2 -2
View File
@@ -5,8 +5,8 @@
import BN from 'bn.js';
import ApiRx from '@polkadot/api/rx/Api';
import { ApiInterface$Rx } from '@polkadot/api/types';
import { BlockNumber } from '@polkadot/types/index';
import { WsProvider } from '@polkadot/rpc-provider/index';
import { BlockNumber } from '@polkadot/types';
import { WsProvider } from '@polkadot/rpc-provider';
const WS_LOCAL = 'ws://127.0.0.1:9944/';
// const WS_POC3 = 'wss://poc3-rpc.polkadot.io/';
+1 -1
View File
@@ -36,6 +36,6 @@
"@polkadot/rpc-rx": "^0.46.11",
"@polkadot/storage": "^0.46.11",
"@polkadot/types": "^0.46.11",
"@polkadot/util-crypto": "^0.36.1"
"@polkadot/util-crypto": "^0.36.3"
}
}
+4 -4
View File
@@ -18,12 +18,12 @@ import {
import EventEmitter from 'eventemitter3';
import { map } from 'rxjs/operators';
import decorateDerive, { Derive as DeriveInterface } from '@polkadot/api-derive/index';
import decorateDerive, { Derive as DeriveInterface } from '@polkadot/api-derive';
import extrinsicsFromMeta from '@polkadot/extrinsics/fromMetadata';
import RpcBase from '@polkadot/rpc-core/index';
import RpcRx from '@polkadot/rpc-rx/index';
import RpcBase from '@polkadot/rpc-core';
import RpcRx from '@polkadot/rpc-rx';
import storageFromMeta from '@polkadot/storage/fromMetadata';
import { Event, getTypeRegistry, Hash, Metadata, Method, RuntimeVersion } from '@polkadot/types/index';
import { Event, getTypeRegistry, Hash, Metadata, Method, RuntimeVersion } from '@polkadot/types';
import { MethodFunction, ModulesWithMethods } from '@polkadot/types/primitive/Method';
import { StorageFunction } from '@polkadot/types/primitive/StorageKey';
import { assert, compactStripLength, isFunction, isObject, isUndefined, logger, u8aToHex } from '@polkadot/util';
+1 -1
View File
@@ -3,7 +3,7 @@
// of the Apache-2.0 license. See the LICENSE file for details.
import { KeyringPair } from '@polkadot/keyring/types';
import { AccountId, Address, ExtrinsicStatus, EventRecord, getTypeRegistry, Hash, Index, Method, SignedBlock, Struct, Text, Vector } from '@polkadot/types/index';
import { AccountId, Address, ExtrinsicStatus, EventRecord, getTypeRegistry, Hash, Index, Method, SignedBlock, Struct, Text, Vector } from '@polkadot/types';
import { Codec, CodecCallback, IExtrinsic, SignatureOptions } from '@polkadot/types/types';
import { ApiInterface$Rx, ApiType, OnCallDefinition, Signer } from './types';
+2 -2
View File
@@ -4,10 +4,10 @@
// Simple non-runnable checks to test type definitions in the editor itself
import { ApiPromise } from '@polkadot/api/index';
import { ApiPromise } from '@polkadot/api';
import testKeyring from '@polkadot/keyring/testingPairs';
import { IExtrinsic, IMethod } from '@polkadot/types/types';
import { Header, HeaderExtended } from '@polkadot/types/index';
import { Header, HeaderExtended } from '@polkadot/types';
export default async function test () {
const api = await ApiPromise.create();
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
export { WsProvider } from '@polkadot/rpc-provider/index';
export { WsProvider } from '@polkadot/rpc-provider';
export { default as ApiPromise } from './promise';
export { default as ApiRx } from './rx';
+2 -2
View File
@@ -3,10 +3,10 @@
// of the Apache-2.0 license. See the LICENSE file for details.
import { Observable } from 'rxjs';
import { DeriveCustom } from '@polkadot/api-derive/index';
import { DeriveCustom } from '@polkadot/api-derive';
import { ProviderInterface } from '@polkadot/rpc-provider/types';
import { RpcRxInterface$Events } from '@polkadot/rpc-rx/types';
import { Hash, Metadata, RuntimeVersion, u64 as U64 } from '@polkadot/types/index';
import { Hash, Metadata, RuntimeVersion, u64 as U64 } from '@polkadot/types';
import {
CodecArg,
CodecCallback,
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import { EventRecord, SignedBlock, U8a } from '@polkadot/types/index';
import { EventRecord, SignedBlock, U8a } from '@polkadot/types';
import l from './logging';
@@ -5,7 +5,7 @@
import { KeyringPair } from '@polkadot/keyring/types';
import { SignatureOptions } from '@polkadot/types/types';
import { Extrinsic } from '@polkadot/types/index';
import { Extrinsic } from '@polkadot/types';
let id = 0;
+1 -1
View File
@@ -33,6 +33,6 @@
"@polkadot/jsonrpc": "^0.46.11",
"@polkadot/rpc-provider": "^0.46.11",
"@polkadot/types": "^0.46.11",
"@polkadot/util": "^0.36.1"
"@polkadot/util": "^0.36.3"
}
}
+1 -1
View File
@@ -5,7 +5,7 @@
import BN from 'bn.js';
import storage from '@polkadot/storage/static';
import Api from './index';
import Api from '.';
const ADDR_ONE = '5EhmTa7fL6SdjgKXo9g6hetR6nHnRAmrtisoGFWEESjzECtY';
const ADDR_TWO = '5FjbQAHSptRU4Q7Py6zDsRnE7UkpZikJVg5nm1tmu3WuZXKd';
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Api from './index';
import Api from '.';
describe('Api', () => {
let api: Api;
+3 -3
View File
@@ -6,10 +6,10 @@ import { ProviderInterface, ProviderInterface$Callback } from '@polkadot/rpc-pro
import { RpcSection, RpcMethod } from '@polkadot/jsonrpc/types';
import { RpcInterface, RpcInterface$Method, RpcInterface$Section } from './types';
import interfaces from '@polkadot/jsonrpc/index';
import { WsProvider } from '@polkadot/rpc-provider/index';
import interfaces from '@polkadot/jsonrpc';
import { WsProvider } from '@polkadot/rpc-provider';
import { Codec } from '@polkadot/types/types';
import { Option, StorageChangeSet, StorageKey, Vector, createClass, createType } from '@polkadot/types/index';
import { Option, StorageChangeSet, StorageKey, Vector, createClass, createType } from '@polkadot/types';
import { ExtError, assert, isFunction, isNull, logger } from '@polkadot/util';
const l = logger('rpc-core');
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Api from './index';
import Api from '.';
describe('methodSend', () => {
let api: Api;
+3 -3
View File
@@ -30,10 +30,10 @@
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/rpc-provider#readme",
"dependencies": {
"@babel/runtime": "^7.3.4",
"@polkadot/keyring": "^0.36.1",
"@polkadot/keyring": "^0.36.3",
"@polkadot/storage": "^0.46.11",
"@polkadot/util": "^0.36.1",
"@polkadot/util-crypto": "^0.36.1",
"@polkadot/util": "^0.36.3",
"@polkadot/util-crypto": "^0.36.3",
"@types/nock": "^9.3.1",
"eventemitter3": "^3.1.0",
"isomorphic-fetch": "^2.2.1",
@@ -3,7 +3,7 @@
// of the Apache-2.0 license. See the LICENSE file for details.
import { JsonRpcResponse } from '../types';
import Coder from './index';
import Coder from '.';
describe('decodeResponse', () => {
let coder: Coder;
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Coder from './index';
import Coder from '.';
describe('encodeJson', () => {
let coder: Coder;
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Coder from './index';
import Coder from '.';
describe('encodeObject', () => {
let coder: Coder;
+1 -1
View File
@@ -4,7 +4,7 @@
import { TEST_HTTP_URL } from '../../test/mockHttp';
import Http from './index';
import Http from '.';
describe('Http', () => {
let http;
+1 -1
View File
@@ -4,7 +4,7 @@
import { mockHttp, TEST_HTTP_URL } from '../../test/mockHttp';
import Http from './index';
import Http from '.';
describe('send', () => {
let http;
+2 -2
View File
@@ -7,12 +7,12 @@ import { MockState$Subscriptions, MockState$Subscription$Callback, MockState$Db
import BN from 'bn.js';
import EventEmitter from 'eventemitter3';
import interfaces from '@polkadot/jsonrpc/index';
import interfaces from '@polkadot/jsonrpc';
import testKeyring from '@polkadot/keyring/testing';
import storage from '@polkadot/storage/static';
import { Codec } from '@polkadot/types/types';
import metadata from '@polkadot/types/Metadata/v0/static';
import { Header } from '@polkadot/types/index';
import { Header } from '@polkadot/types';
import { bnToU8a, logger, u8aToHex } from '@polkadot/util';
import { randomAsU8a } from '@polkadot/util-crypto';
+1 -1
View File
@@ -4,7 +4,7 @@
import { ProviderInterface$Emitted } from '../types';
import Mock from './index';
import Mock from '.';
describe('on', () => {
let mock: Mock;
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Mock from './index';
import Mock from '.';
describe('send', () => {
let mock: Mock;
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Mock from './index';
import Mock from '.';
describe('subscribe', () => {
let mock: Mock;
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Mock from './index';
import Mock from '.';
describe('unsubscribe', () => {
let mock: Mock;
+1 -1
View File
@@ -4,7 +4,7 @@
import { mockWs, TEST_WS_URL } from '../../test/mockWs';
import Ws from './index';
import Ws from '.';
describe('onConnect', () => {
let mock;
+1 -1
View File
@@ -4,7 +4,7 @@
import { mockWs, TEST_WS_URL } from '../../test/mockWs';
import Ws from './index';
import Ws from '.';
let ws;
let mock;
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Ws from './index';
import Ws from '.';
describe('onMessageResult', () => {
let ws;
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Ws from './index';
import Ws from '.';
describe('onMessageSubscribe', () => {
let ws;
+1 -1
View File
@@ -4,7 +4,7 @@
import { mockWs, TEST_WS_URL } from '../../test/mockWs';
import Ws from './index';
import Ws from '.';
let ws;
let mock;
+1 -1
View File
@@ -4,7 +4,7 @@
import { mockWs, TEST_WS_URL } from '../../test/mockWs';
import Ws from './index';
import Ws from '.';
let ws;
let mock;
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import Ws from './index';
import Ws from '.';
describe('state', () => {
it('requires an ws:// prefixed endpoint', () => {
@@ -4,7 +4,7 @@
import { mockWs, TEST_WS_URL } from '../../test/mockWs';
import Ws from './index';
import Ws from '.';
let ws;
let mock;
@@ -4,7 +4,7 @@
import { mockWs, TEST_WS_URL } from '../../test/mockWs';
import Ws from './index';
import Ws from '.';
let ws;
let mock;
+1 -1
View File
@@ -11,7 +11,7 @@ jest.mock('@polkadot/rpc-provider/ws', () => class {
send = () => true;
});
import RpcRx from './index';
import RpcRx from '.';
describe('createCachedObservable', () => {
let api: RpcRx;
+1 -1
View File
@@ -10,7 +10,7 @@ jest.mock('@polkadot/rpc-provider/ws', () => class {
send = () => true;
});
import RpcRx from './index';
import RpcRx from '.';
describe('RpcRx', () => {
let api: RpcRx;
+1 -1
View File
@@ -9,7 +9,7 @@ import { RpcRxInterface, RpcRxInterface$Events, RpcRxInterface$Method, RpcRxInte
import EventEmitter from 'eventemitter3';
import memoize, { Memoized } from 'memoizee';
import { BehaviorSubject, Observable, from, Observer } from 'rxjs';
import Rpc from '@polkadot/rpc-core/index';
import Rpc from '@polkadot/rpc-core';
import { map, publishReplay, refCount } from 'rxjs/operators';
import { isFunction, isUndefined } from '@polkadot/util';
+1 -1
View File
@@ -11,7 +11,7 @@ jest.mock('@polkadot/rpc-provider/ws', () => class {
send = () => true;
});
import RpcRx from './index';
import RpcRx from '.';
describe('replay', () => {
const params = [123, false];
+1 -1
View File
@@ -12,6 +12,6 @@
"dependencies": {
"@babel/runtime": "^7.3.4",
"@polkadot/types": "^0.46.11",
"@polkadot/util": "^0.36.1"
"@polkadot/util": "^0.36.3"
}
}
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import { Extrinsic, Metadata } from '@polkadot/types/index';
import { Extrinsic, Metadata } from '@polkadot/types';
import json from '@polkadot/types/Metadata/v0/static';
import fromMetadata from './fromMetadata';
+1 -1
View File
@@ -9,7 +9,7 @@ import MetadataV0 from '@polkadot/types/Metadata/v0';
import { stringCamelCase } from '@polkadot/util';
import createUnchecked from './utils/createUnchecked';
import extrinsics from './index';
import extrinsics from '.';
/**
* Extend a storage object with the storage modules & module functions present
+1 -1
View File
@@ -3,7 +3,7 @@
// of the Apache-2.0 license. See the LICENSE file for details.
import testingPairs from '@polkadot/keyring/testingPairs';
import { Extrinsic } from '@polkadot/types/index';
import { Extrinsic } from '@polkadot/types';
import extrinsics from './static';
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import { Metadata } from '@polkadot/types/index';
import { Metadata } from '@polkadot/types';
import metadataRpc from '@polkadot/types/Metadata/v0/static';
import { ModulesWithMethods } from '@polkadot/types/primitive/Method';
@@ -4,7 +4,7 @@
import { FunctionMetadata } from '@polkadot/types/Metadata/v0/Modules';
import { MethodFunction } from '@polkadot/types/primitive/Method';
import { Method } from '@polkadot/types/index';
import { Method } from '@polkadot/types';
import { assert } from '@polkadot/util';
/**
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import interfaces from './index';
import interfaces from '.';
describe('jsonrpc', () => {
it('exports the available interfaces', () => {
+3 -3
View File
@@ -30,9 +30,9 @@
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/type-storage#readme",
"dependencies": {
"@babel/runtime": "^7.3.4",
"@polkadot/keyring": "^0.36.1",
"@polkadot/keyring": "^0.36.3",
"@polkadot/types": "^0.46.11",
"@polkadot/util": "^0.36.1",
"@polkadot/util-crypto": "^0.36.1"
"@polkadot/util": "^0.36.3",
"@polkadot/util-crypto": "^0.36.3"
}
}
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import { Metadata } from '@polkadot/types/index';
import { Metadata } from '@polkadot/types';
import json from '@polkadot/types/Metadata/v0/static';
import fromMetadata from './fromMetadata';
+1 -1
View File
@@ -8,7 +8,7 @@ import MetadataV0 from '@polkadot/types/Metadata/v0';
import { stringLowerFirst } from '@polkadot/util';
import createFunction from './utils/createFunction';
import storage from './index';
import storage from '.';
/**
* Extend a storage object with the storage modules & module functions present
+1 -1
View File
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import { Metadata } from '@polkadot/types/index';
import { Metadata } from '@polkadot/types';
import metadataRpc from '@polkadot/types/Metadata/v0/static';
import fromMetadata from './fromMetadata';
+1 -1
View File
@@ -4,7 +4,7 @@
import { StorageFunctionMetadata, StorageFunctionModifier, StorageFunctionType } from '@polkadot/types/Metadata/v0/Modules';
import { StorageFunction } from '@polkadot/types/primitive/StorageKey';
import { Text, Vector } from '@polkadot/types/index';
import { Text, Vector } from '@polkadot/types';
import createFunction from './utils/createFunction';
@@ -4,7 +4,7 @@
import { StorageFunctionMetadata } from '@polkadot/types/Metadata/v0/Modules';
import { StorageFunction } from '@polkadot/types/primitive/StorageKey';
import { Compact, Text, createType } from '@polkadot/types/index';
import { Compact, Text, createType } from '@polkadot/types';
import { assert, isNull, isUndefined, stringLowerFirst, stringToU8a, u8aConcat } from '@polkadot/util';
import { xxhashAsU8a } from '@polkadot/util-crypto';
+2 -2
View File
@@ -30,8 +30,8 @@
"homepage": "https://github.com/polkadot-js/api/tree/master/packages/types#readme",
"dependencies": {
"@babel/runtime": "^7.3.4",
"@polkadot/keyring": "^0.36.1",
"@polkadot/util": "^0.36.1",
"@polkadot/keyring": "^0.36.3",
"@polkadot/util": "^0.36.3",
"core-js": "^2.6.5"
}
}
+1 -1
View File
@@ -7,7 +7,7 @@ import { EventMetadata, OuterEventMetadata, OuterEventMetadataEvent } from '../v
import { CallMetadata, FunctionMetadata, RuntimeModuleMetadata, ModuleMetadata, StorageFunctionMetadata, StorageMetadata } from '../v0/Modules';
import MetadataV0 from '../v0/Metadata';
import MetadataV1, { MetadataModuleV1 } from './index';
import MetadataV1, { MetadataModuleV1 } from '.';
function storageV0 (mod: MetadataModuleV1): StorageMetadata | null {
if (mod.storage.isNone) {
@@ -2,7 +2,7 @@
// This software may be modified and distributed under the terms
// of the Apache-2.0 license. See the LICENSE file for details.
import { createType } from '@polkadot/types/index';
import { createType } from '@polkadot/types';
import json from '../json/StorageChangeSet.001.json';
import StorageChangeSet from './StorageChangeSet';
+9
View File
@@ -5,14 +5,23 @@
"baseUrl": ".",
"paths":
{
"@polkadot/api": ["packages/api/src"],
"@polkadot/api/*": ["packages/api/src/*"],
"@polkadot/api-derive": ["packages/api-derive/src"],
"@polkadot/api-derive/*": ["packages/api-derive/src/*"],
"@polkadot/rpc-core": ["packages/rpc-core/src"],
"@polkadot/rpc-core/*": ["packages/rpc-core/src/*"],
"@polkadot/rpc-provider": ["packages/rpc-provider/src"],
"@polkadot/rpc-provider/*": ["packages/rpc-provider/src/*"],
"@polkadot/rpc-rx": ["packages/rpc-rx/src"],
"@polkadot/rpc-rx/*": ["packages/rpc-rx/src/*"],
"@polkadot/extrinsics": ["packages/type-extrinsics/src"],
"@polkadot/extrinsics/*": ["packages/type-extrinsics/src/*"],
"@polkadot/jsonrpc": ["packages/type-jsonrpc/src"],
"@polkadot/jsonrpc/*": ["packages/type-jsonrpc/src/*"],
"@polkadot/storage": ["packages/type-storage/src"],
"@polkadot/storage/*": ["packages/type-storage/src/*"],
"@polkadot/types": ["packages/types/src"],
"@polkadot/types/*": ["packages/types/src/*"]
},
"typeRoots": [
+15 -15
View File
@@ -1429,14 +1429,14 @@
typescript "^3.3.3333"
vuepress "^1.0.0-alpha.40"
"@polkadot/keyring@^0.36.1":
version "0.36.1"
resolved "https://registry.yarnpkg.com/@polkadot/keyring/-/keyring-0.36.1.tgz#c34b4c8132e96e80a374b906c7190f39c92e5eb5"
integrity sha512-LTEPA2IGjr6v0Q4UdWb8vhVCJMV1Iy9++vKFNm/MVjedwYAtcaHa2UqmjgejJhndHf1DJLKZvQYFHmPUUDI4jQ==
"@polkadot/keyring@^0.36.3":
version "0.36.3"
resolved "https://registry.yarnpkg.com/@polkadot/keyring/-/keyring-0.36.3.tgz#4114f17f71137daee6f8f21ec22642a30d54360f"
integrity sha512-1k/NHaEJpIAyUm2skr4yf0gWE6EiFdDcd28CZj1Ta63reKUJfcxbWbcebSDoW8KZLbkDgH8GLe5l6sEuux7a/w==
dependencies:
"@babel/runtime" "^7.3.4"
"@polkadot/util" "^0.36.1"
"@polkadot/util-crypto" "^0.36.1"
"@polkadot/util" "^0.36.3"
"@polkadot/util-crypto" "^0.36.3"
"@types/bs58" "^4.0.0"
bs58 "^4.0.1"
@@ -1450,14 +1450,14 @@
resolved "https://registry.yarnpkg.com/@polkadot/ts/-/ts-0.1.56.tgz#ffd6e9c95704a7fb90b918193b9dc5c440114b27"
integrity sha512-wnt4zXxZXyz6WaubTO/I+nUElwV2DogFzdl6CrKfVn2PTWp8uHN06W9s40FH57ORtmQfDr9rLRP8Nq+oIyElbg==
"@polkadot/util-crypto@^0.36.1":
version "0.36.1"
resolved "https://registry.yarnpkg.com/@polkadot/util-crypto/-/util-crypto-0.36.1.tgz#8a706939bd9e2066a53f42c5573ca9b845be3827"
integrity sha512-To17e43Tl+a3b08BtM9LSoK9j49xnDA/V3YxNclHFMur+JEsraMYooNQegfehcQTCbnnkZW+j+TeadlvN1OCBw==
"@polkadot/util-crypto@^0.36.3":
version "0.36.3"
resolved "https://registry.yarnpkg.com/@polkadot/util-crypto/-/util-crypto-0.36.3.tgz#abf585e9ef55a3c2c53419ab7d14a3db36cb6a9a"
integrity sha512-QMNSYkd3ZT0lD771P0ozEzplUf/YHhflS0Y0v17Z2oEBx2tSFa6MQ9R+fLXT6lFKOExnSHnJmNszZfwns4EyDg==
dependencies:
"@babel/runtime" "^7.3.4"
"@polkadot/schnorrkel-js" "^0.1.2-3"
"@polkadot/util" "^0.36.1"
"@polkadot/util" "^0.36.3"
"@types/bip39" "^2.4.2"
"@types/pbkdf2" "^3.0.0"
"@types/secp256k1" "^3.5.0"
@@ -1470,10 +1470,10 @@
tweetnacl "^1.0.1"
xxhashjs "^0.2.2"
"@polkadot/util@^0.36.1":
version "0.36.1"
resolved "https://registry.yarnpkg.com/@polkadot/util/-/util-0.36.1.tgz#680b3e9358a9131f05a2e4fe7938cb03065a7afa"
integrity sha512-lAILZlBhPoSowtX1wjkZiJDE0y2TYLqe7QMQSaDvk5/u4VT9ZcSqdoIqeZWy0YInG8ISW3bd9L7rjNGmUGKpCg==
"@polkadot/util@^0.36.3":
version "0.36.3"
resolved "https://registry.yarnpkg.com/@polkadot/util/-/util-0.36.3.tgz#de5fa37d7bfd7af3f1cb549d38f69b4114ee35ea"
integrity sha512-biDXsSSsJw1gVoobqBHFXE1RzXMz5DWAERO5h02ZwKRSsJROISsHzlD0MF4fNmiIzcHJ5pe08Ul6YzR1ZPhGEw==
dependencies:
"@babel/runtime" "^7.3.4"
"@types/bn.js" "^4.11.4"