@polkadot/rpc-core 14.3.1 → 15.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bundle.d.ts CHANGED
@@ -6,6 +6,9 @@ export * from './util/index.js';
6
6
  interface Options {
7
7
  isPedantic?: boolean;
8
8
  provider: ProviderInterface;
9
+ /**
10
+ * Custom size of the rpc LRUCache capacity. Defaults to `RPC_CORE_DEFAULT_CAPACITY` (1024 * 10 * 10)
11
+ */
9
12
  rpcCacheCapacity?: number;
10
13
  userRpc?: Record<string, Record<string, DefinitionRpc | DefinitionRpcSub>>;
11
14
  }
@@ -40,7 +43,9 @@ export declare class RpcCore {
40
43
  /**
41
44
  * @constructor
42
45
  * Default constructor for the core RPC handler
43
- * @param {ProviderInterface} provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
46
+ * @param {Registry} registry Type Registry
47
+ * @param {ProviderInterface} options.provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
48
+ * @param {number} [options.rpcCacheCapacity] Custom size of the rpc LRUCache capacity. Defaults to `RPC_CORE_DEFAULT_CAPACITY` (1024 * 10 * 10)
44
49
  */
45
50
  constructor(instanceId: string, registry: Registry, { isPedantic, provider, rpcCacheCapacity, userRpc }: Options);
46
51
  /**
package/bundle.js CHANGED
@@ -64,7 +64,9 @@ export class RpcCore {
64
64
  /**
65
65
  * @constructor
66
66
  * Default constructor for the core RPC handler
67
- * @param {ProviderInterface} provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
67
+ * @param {Registry} registry Type Registry
68
+ * @param {ProviderInterface} options.provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
69
+ * @param {number} [options.rpcCacheCapacity] Custom size of the rpc LRUCache capacity. Defaults to `RPC_CORE_DEFAULT_CAPACITY` (1024 * 10 * 10)
68
70
  */
69
71
  constructor(instanceId, registry, { isPedantic = true, provider, rpcCacheCapacity, userRpc = {} }) {
70
72
  if (!provider || !isFunction(provider.send)) {
package/cjs/bundle.d.ts CHANGED
@@ -6,6 +6,9 @@ export * from './util/index.js';
6
6
  interface Options {
7
7
  isPedantic?: boolean;
8
8
  provider: ProviderInterface;
9
+ /**
10
+ * Custom size of the rpc LRUCache capacity. Defaults to `RPC_CORE_DEFAULT_CAPACITY` (1024 * 10 * 10)
11
+ */
9
12
  rpcCacheCapacity?: number;
10
13
  userRpc?: Record<string, Record<string, DefinitionRpc | DefinitionRpcSub>>;
11
14
  }
@@ -40,7 +43,9 @@ export declare class RpcCore {
40
43
  /**
41
44
  * @constructor
42
45
  * Default constructor for the core RPC handler
43
- * @param {ProviderInterface} provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
46
+ * @param {Registry} registry Type Registry
47
+ * @param {ProviderInterface} options.provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
48
+ * @param {number} [options.rpcCacheCapacity] Custom size of the rpc LRUCache capacity. Defaults to `RPC_CORE_DEFAULT_CAPACITY` (1024 * 10 * 10)
44
49
  */
45
50
  constructor(instanceId: string, registry: Registry, { isPedantic, provider, rpcCacheCapacity, userRpc }: Options);
46
51
  /**
package/cjs/bundle.js CHANGED
@@ -69,7 +69,9 @@ class RpcCore {
69
69
  /**
70
70
  * @constructor
71
71
  * Default constructor for the core RPC handler
72
- * @param {ProviderInterface} provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
72
+ * @param {Registry} registry Type Registry
73
+ * @param {ProviderInterface} options.provider An API provider using any of the supported providers (HTTP, SC or WebSocket)
74
+ * @param {number} [options.rpcCacheCapacity] Custom size of the rpc LRUCache capacity. Defaults to `RPC_CORE_DEFAULT_CAPACITY` (1024 * 10 * 10)
73
75
  */
74
76
  constructor(instanceId, registry, { isPedantic = true, provider, rpcCacheCapacity, userRpc = {} }) {
75
77
  if (!provider || !(0, util_1.isFunction)(provider.send)) {
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.packageInfo = void 0;
4
- exports.packageInfo = { name: '@polkadot/rpc-core', path: typeof __dirname === 'string' ? __dirname : 'auto', type: 'cjs', version: '14.3.1' };
4
+ exports.packageInfo = { name: '@polkadot/rpc-core', path: typeof __dirname === 'string' ? __dirname : 'auto', type: 'cjs', version: '15.0.1' };
package/package.json CHANGED
@@ -18,7 +18,7 @@
18
18
  "./cjs/packageDetect.js"
19
19
  ],
20
20
  "type": "module",
21
- "version": "14.3.1",
21
+ "version": "15.0.1",
22
22
  "main": "./cjs/index.js",
23
23
  "module": "./index.js",
24
24
  "types": "./index.d.ts",
@@ -199,9 +199,9 @@
199
199
  }
200
200
  },
201
201
  "dependencies": {
202
- "@polkadot/rpc-augment": "14.3.1",
203
- "@polkadot/rpc-provider": "14.3.1",
204
- "@polkadot/types": "14.3.1",
202
+ "@polkadot/rpc-augment": "15.0.1",
203
+ "@polkadot/rpc-provider": "15.0.1",
204
+ "@polkadot/types": "15.0.1",
205
205
  "@polkadot/util": "^13.2.3",
206
206
  "rxjs": "^7.8.1",
207
207
  "tslib": "^2.8.0"
package/packageInfo.js CHANGED
@@ -1 +1 @@
1
- export const packageInfo = { name: '@polkadot/rpc-core', path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto', type: 'esm', version: '14.3.1' };
1
+ export const packageInfo = { name: '@polkadot/rpc-core', path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto', type: 'esm', version: '15.0.1' };