@libp2p/echo 2.1.1 → 2.1.2
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/dist/src/index.d.ts +2 -2
- package/dist/src/index.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/index.ts +2 -2
package/dist/src/index.d.ts
CHANGED
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
* // write/read stream
|
|
42
42
|
* ```
|
|
43
43
|
*/
|
|
44
|
-
import type { ComponentLogger, PeerId } from '@libp2p/interface';
|
|
44
|
+
import type { AbortOptions, ComponentLogger, PeerId } from '@libp2p/interface';
|
|
45
45
|
import type { ConnectionManager, Registrar } from '@libp2p/interface-internal';
|
|
46
46
|
import type { Multiaddr } from '@multiformats/multiaddr';
|
|
47
47
|
export interface EchoInit {
|
|
@@ -57,7 +57,7 @@ export interface EchoComponents {
|
|
|
57
57
|
}
|
|
58
58
|
export interface Echo {
|
|
59
59
|
protocol: string;
|
|
60
|
-
echo(peer: PeerId | Multiaddr | Multiaddr[], buf: Uint8Array): Promise<Uint8Array>;
|
|
60
|
+
echo(peer: PeerId | Multiaddr | Multiaddr[], buf: Uint8Array, options?: AbortOptions): Promise<Uint8Array>;
|
|
61
61
|
}
|
|
62
62
|
export declare function echo(init?: EchoInit): (components: EchoComponents) => Echo;
|
|
63
63
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/src/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AAGH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AAGH,OAAO,KAAK,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAA;AAC9E,OAAO,KAAK,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAA;AAC9E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAA;AAExD,MAAM,WAAW,QAAQ;IACvB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,sBAAsB,CAAC,EAAE,OAAO,CAAA;CACjC;AAED,MAAM,WAAW,cAAc;IAC7B,SAAS,EAAE,SAAS,CAAA;IACpB,iBAAiB,EAAE,iBAAiB,CAAA;IACpC,MAAM,EAAE,eAAe,CAAA;CACxB;AAED,MAAM,WAAW,IAAI;IACnB,QAAQ,EAAE,MAAM,CAAA;IAChB,IAAI,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS,EAAE,EAAE,GAAG,EAAE,UAAU,EAAE,OAAO,CAAC,EAAE,YAAY,GAAG,OAAO,CAAC,UAAU,CAAC,CAAA;CAC3G;AAED,wBAAgB,IAAI,CAAE,IAAI,GAAE,QAAa,GAAG,CAAC,UAAU,EAAE,cAAc,KAAK,IAAI,CAE/E"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@libp2p/echo",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.2",
|
|
4
4
|
"description": "Implementation of an Echo protocol",
|
|
5
5
|
"license": "Apache-2.0 OR MIT",
|
|
6
6
|
"homepage": "https://github.com/libp2p/js-libp2p/tree/main/packages/protocol-echo#readme",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
54
|
"@libp2p/interface": "^2.2.0",
|
|
55
|
-
"@libp2p/interface-internal": "^2.0
|
|
55
|
+
"@libp2p/interface-internal": "^2.1.0",
|
|
56
56
|
"@multiformats/multiaddr": "^12.3.1",
|
|
57
57
|
"it-byte-stream": "^1.1.0",
|
|
58
58
|
"it-pipe": "^3.0.1"
|
package/src/index.ts
CHANGED
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
*/
|
|
44
44
|
|
|
45
45
|
import { Echo as EchoClass } from './echo.js'
|
|
46
|
-
import type { ComponentLogger, PeerId } from '@libp2p/interface'
|
|
46
|
+
import type { AbortOptions, ComponentLogger, PeerId } from '@libp2p/interface'
|
|
47
47
|
import type { ConnectionManager, Registrar } from '@libp2p/interface-internal'
|
|
48
48
|
import type { Multiaddr } from '@multiformats/multiaddr'
|
|
49
49
|
|
|
@@ -62,7 +62,7 @@ export interface EchoComponents {
|
|
|
62
62
|
|
|
63
63
|
export interface Echo {
|
|
64
64
|
protocol: string
|
|
65
|
-
echo(peer: PeerId | Multiaddr | Multiaddr[], buf: Uint8Array): Promise<Uint8Array>
|
|
65
|
+
echo(peer: PeerId | Multiaddr | Multiaddr[], buf: Uint8Array, options?: AbortOptions): Promise<Uint8Array>
|
|
66
66
|
}
|
|
67
67
|
|
|
68
68
|
export function echo (init: EchoInit = {}): (components: EchoComponents) => Echo {
|