@libp2p/interface 0.1.3 → 0.1.4-16a87076

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/README.md CHANGED
@@ -1,5 +1,3 @@
1
- # @libp2p/interface <!-- omit in toc -->
2
-
3
1
  [![libp2p.io](https://img.shields.io/badge/project-libp2p-yellow.svg?style=flat-square)](http://libp2p.io/)
4
2
  [![Discuss](https://img.shields.io/discourse/https/discuss.libp2p.io/posts.svg?style=flat-square)](https://discuss.libp2p.io)
5
3
  [![codecov](https://img.shields.io/codecov/c/github/libp2p/js-libp2p.svg?style=flat-square)](https://codecov.io/gh/libp2p/js-libp2p)
@@ -7,21 +5,13 @@
7
5
 
8
6
  > The interface implemented by a libp2p node
9
7
 
10
- ## Table of contents <!-- omit in toc -->
11
-
12
- - [Install](#install)
13
- - [Browser `<script>` tag](#browser-script-tag)
14
- - [API Docs](#api-docs)
15
- - [License](#license)
16
- - [Contribution](#contribution)
17
-
18
- ## Install
8
+ # Install
19
9
 
20
10
  ```console
21
11
  $ npm i @libp2p/interface
22
12
  ```
23
13
 
24
- ### Browser `<script>` tag
14
+ ## Browser `<script>` tag
25
15
 
26
16
  Loading this module through a script tag will make it's exports available as `Libp2pInterface` in the global namespace.
27
17
 
@@ -29,17 +19,17 @@ Loading this module through a script tag will make it's exports available as `Li
29
19
  <script src="https://unpkg.com/@libp2p/interface/dist/index.min.js"></script>
30
20
  ```
31
21
 
32
- ## API Docs
22
+ # API Docs
33
23
 
34
24
  - <https://libp2p.github.io/js-libp2p/modules/_libp2p_interface.html>
35
25
 
36
- ## License
26
+ # License
37
27
 
38
28
  Licensed under either of
39
29
 
40
30
  - Apache 2.0, ([LICENSE-APACHE](LICENSE-APACHE) / <http://www.apache.org/licenses/LICENSE-2.0>)
41
31
  - MIT ([LICENSE-MIT](LICENSE-MIT) / <http://opensource.org/licenses/MIT>)
42
32
 
43
- ## Contribution
33
+ # Contribution
44
34
 
45
35
  Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
@@ -0,0 +1,3 @@
1
+ /** Noop for browser compatibility */
2
+ export declare function setMaxListeners(): void;
3
+ //# sourceMappingURL=events.browser.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"events.browser.d.ts","sourceRoot":"","sources":["../../src/events.browser.ts"],"names":[],"mappings":"AAAA,qCAAqC;AACrC,wBAAgB,eAAe,IAAK,IAAI,CAAG"}
@@ -0,0 +1,3 @@
1
+ /** Noop for browser compatibility */
2
+ export function setMaxListeners() { }
3
+ //# sourceMappingURL=events.browser.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"events.browser.js","sourceRoot":"","sources":["../../src/events.browser.ts"],"names":[],"mappings":"AAAA,qCAAqC;AACrC,MAAM,UAAU,eAAe,KAAW,CAAC"}
@@ -1,3 +1,5 @@
1
+ /// <reference types="node" />
2
+ import { setMaxListeners as nodeSetMaxListeners } from 'events';
1
3
  export interface EventCallback<EventType> {
2
4
  (evt: EventType): void;
3
5
  }
@@ -13,7 +15,18 @@ export type EventHandler<EventType> = EventCallback<EventType> | EventObject<Eve
13
15
  * https://github.com/microsoft/TypeScript/issues/299
14
16
  * etc
15
17
  */
16
- export declare class EventEmitter<EventMap extends Record<string, any>> extends EventTarget {
18
+ export interface TypedEventTarget<EventMap extends Record<string, any>> extends EventTarget {
19
+ addEventListener<K extends keyof EventMap>(type: K, listener: EventHandler<EventMap[K]> | null, options?: boolean | AddEventListenerOptions): void;
20
+ listenerCount(type: string): number;
21
+ removeEventListener<K extends keyof EventMap>(type: K, listener?: EventHandler<EventMap[K]> | null, options?: boolean | EventListenerOptions): void;
22
+ removeEventListener(type: string, listener?: EventHandler<Event>, options?: boolean | EventListenerOptions): void;
23
+ safeDispatchEvent<Detail>(type: keyof EventMap, detail: CustomEventInit<Detail>): boolean;
24
+ }
25
+ /**
26
+ * An implementation of a typed event target
27
+ * etc
28
+ */
29
+ export declare class TypedEventEmitter<EventMap extends Record<string, any>> extends EventTarget implements TypedEventTarget<EventMap> {
17
30
  #private;
18
31
  listenerCount(type: string): number;
19
32
  addEventListener<K extends keyof EventMap>(type: K, listener: EventHandler<EventMap[K]> | null, options?: boolean | AddEventListenerOptions): void;
@@ -25,4 +38,6 @@ export declare const CustomEvent: {
25
38
  new <T>(type: string, eventInitDict?: CustomEventInit<T> | undefined): CustomEvent<T>;
26
39
  prototype: CustomEvent<any>;
27
40
  };
41
+ export { TypedEventEmitter as EventEmitter };
42
+ export declare const setMaxListeners: typeof nodeSetMaxListeners;
28
43
  //# sourceMappingURL=events.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/events.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,aAAa,CAAC,SAAS;IAAI,CAAC,GAAG,EAAE,SAAS,GAAG,IAAI,CAAA;CAAE;AACpE,MAAM,WAAW,WAAW,CAAC,SAAS;IAAI,WAAW,EAAE,aAAa,CAAC,SAAS,CAAC,CAAA;CAAE;AACjF,MAAM,MAAM,YAAY,CAAC,SAAS,IAAI,aAAa,CAAC,SAAS,CAAC,GAAG,WAAW,CAAC,SAAS,CAAC,CAAA;AAOvF;;;;;;;GAOG;AACH,qBAAa,YAAY,CAAC,QAAQ,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAE,SAAQ,WAAW;;IAGjF,aAAa,CAAE,IAAI,EAAE,MAAM,GAAG,MAAM;IAUpC,gBAAgB,CAAC,CAAC,SAAS,MAAM,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE,QAAQ,EAAE,YAAY,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,GAAG,IAAI,EAAE,OAAO,CAAC,EAAE,OAAO,GAAG,uBAAuB,GAAG,IAAI;IAiBlJ,mBAAmB,CAAC,CAAC,SAAS,MAAM,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE,QAAQ,CAAC,E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AAI,YAAY,EAAE,CAAA;AAG5C,eAAO,MAAM,eAAe,EAAE,OAAO,mBAMpC,CAAA"}
@@ -1,12 +1,9 @@
1
+ import { setMaxListeners as nodeSetMaxListeners } from 'events';
1
2
  /**
2
- * Adds types to the EventTarget class. Hopefully this won't be necessary forever.
3
- *
4
- * https://github.com/microsoft/TypeScript/issues/28357
5
- * https://github.com/microsoft/TypeScript/issues/43477
6
- * https://github.com/microsoft/TypeScript/issues/299
3
+ * An implementation of a typed event target
7
4
  * etc
8
5
  */
9
- export class EventEmitter extends EventTarget {
6
+ export class TypedEventEmitter extends EventTarget {
10
7
  #listeners = new Map();
11
8
  listenerCount(type) {
12
9
  const listeners = this.#listeners.get(type);
@@ -67,4 +64,15 @@ class CustomEventPolyfill extends Event {
67
64
  }
68
65
  }
69
66
  export const CustomEvent = globalThis.CustomEvent ?? CustomEventPolyfill;
67
+ // TODO: remove this in v1
68
+ export { TypedEventEmitter as EventEmitter };
69
+ // create a setMaxListeners that doesn't break browser usage
70
+ export const setMaxListeners = (n, ...eventTargets) => {
71
+ try {
72
+ nodeSetMaxListeners(n, ...eventTargets);
73
+ }
74
+ catch {
75
+ // swallow error, gulp
76
+ }
77
+ };
70
78
  //# sourceMappingURL=events.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"events.js","sourceRoot":"","sources":["../../src/events.ts"],"names":[],"mappings":"AASA;;;;;;;GAOG;AACH,MAAM,OAAO,YAAmD,SAAQ,WAAW;IACjF,UAAU,GAAG,IAAI,GAAG,EAAmB,CAAA;IAEvC,aAAa,CAAE,IAAY;QACzB,MAAM,SAAS,GAAG,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,CAAC,CAAA;QAE3C,IAAI,SAAS,IAAI,IAAI,EAAE;YACrB,OAAO,CAAC,CAAA;SACT;QAED,OAAO,SAAS,CAAC,MAAM,CAAA;IACzB,CAAC;IAGD,gBAAgB,CAAE,IAAY,EAAE,QAA6B,EAAE,OAA2C;QACxG,KAAK,CAA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AAE,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,CAAA;QACvC,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,EAAE,IAAI,CAAC,CAAA;QAErC,OAAO,MAAM,CAAA;IACf,CAAC;IAED,iBAAiB,CAAS,IAAoB,EAAE,MAA+B;QAC7E,OAAO,IAAI,CAAC,aAAa,CAAC,IAAI,WAAW,CAAS,IAAc,EAAE,MAAM,CAAC,CAAC,CAAA;IAC5E,CAAC;CACF;AAED;;;;;;GAMG;AACH,MAAM,mBAA6B,SAAQ,KAAK;IAC9C,2FAA2F;IACpF,MAAM,CAAG;IAEhB,YAAa,OAAe,EAAE,IAAgC;QAC5D,KAAK,CAAC,OAAO,EAAE,IAAI,CAAC,CAAA;QACpB,sCAAsC;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,EAAE,MAAM,CAAA;IAC5B,CAAC;CACF;AAED,MAAM,CAAC,MAAM,WAAW,GAAG,UAAU,CAAC,WAAW,IAAI,mBAAmB,CAAA;AAExE,0BAA0B;AAC1B,OAAO,EAAE,iBAAiB,IAAI,YAAY,EAAE,CAAA;AAE5C,4DAA4D;AAC5D,MAAM,CAAC,MAAM,eAAe,GAA+B,CAAC,CAAC,EAAE,GAAG,YAAY,EAAE,EAAE;IAChF,IAAI;QACF,mBAAmB,CAAC,CAAC,EAAE,GAAG,YAAY,CAAC,CAAA;KACxC;IAAC,MAAM;QACN,sBAAsB;KACvB;AACH,CAAC,CAAA"}
@@ -15,7 +15,7 @@
15
15
  */
16
16
  import type { Connection, NewStreamOptions, Stream } from './connection/index.js';
17
17
  import type { ContentRouting } from './content-routing/index.js';
18
- import type { EventEmitter } from './events.js';
18
+ import type { TypedEventTarget } from './events.js';
19
19
  import type { KeyChain } from './keychain/index.js';
20
20
  import type { Metrics } from './metrics/index.js';
21
21
  import type { PeerId } from './peer-id/index.js';
@@ -87,6 +87,10 @@ export interface IdentifyResult {
87
87
  * If sent by the remote peer this is the deserialized signed peer record
88
88
  */
89
89
  signedPeerRecord?: SignedPeerRecord;
90
+ /**
91
+ * The connection that the identify protocol ran over
92
+ */
93
+ connection: Connection;
90
94
  }
91
95
  /**
92
96
  * Once you have a libp2p instance, you can listen to several events it emits,
@@ -271,7 +275,7 @@ export interface PendingDial {
271
275
  /**
272
276
  * Libp2p nodes implement this interface.
273
277
  */
274
- export interface Libp2p<T extends ServiceMap = ServiceMap> extends Startable, EventEmitter<Libp2pEvents<T>> {
278
+ export interface Libp2p<T extends ServiceMap = ServiceMap> extends Startable, TypedEventTarget<Libp2pEvents<T>> {
275
279
  /**
276
280
  * The PeerId is a unique identifier for a node on the network.
277
281
  *
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAA;AACjF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAA;AAChE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC/C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAA;AACnD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AACjD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAA;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AACpD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAC1D,OAAO,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAA;AACrE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC/C,OAAO,KAAK,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAA;AACpF,OA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Q,GAAG,OAAO,CAAC,MAAM,CAAC,CAAA;IAE/D;;;;;;;;;;;OAWG;IACH,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAA;IAE5B;;;;OAIG;IACH,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,YAAY,GAAG,OAAO,CAAC,UAAU,CAAC,CAAA;IAEvE;;OAEG;IACH,QAAQ,EAAE,CAAC,CAAA;CACZ;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,WAAW,YAAY;IAC3B,MAAM,CAAC,EAAE,WAAW,CAAA;CACrB;AAED;;;;GAIG;AACH,MAAM,MAAM,gBAAgB,CAAC,CAAC,IAAI;KAC/B,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,KAAK,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,gBAAgB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;CACjJ,CAAA"}
@@ -1,4 +1,4 @@
1
- import type { EventEmitter } from '../events.js';
1
+ import type { TypedEventTarget } from '../events.js';
2
2
  import type { PeerInfo } from '../peer-info/index.js';
3
3
  /**
4
4
  * Any object that implements this Symbol as a property should return a
@@ -23,6 +23,6 @@ export declare const peerDiscovery: unique symbol;
23
23
  export interface PeerDiscoveryEvents {
24
24
  'peer': CustomEvent<PeerInfo>;
25
25
  }
26
- export interface PeerDiscovery extends EventEmitter<PeerDiscoveryEvents> {
26
+ export interface PeerDiscovery extends TypedEventTarget<PeerDiscoveryEvents> {
27
27
  }
28
28
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/peer-discovery/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAChD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAErD;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,aAAa,eAAuC,CAAA;AAEjE,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,WAAW,CAAC,QAAQ,CAAC,CAAA;CAC9B;AAED,MAAM,WAAW,aAAc,SAAQ,YAAY,CAAC,mBAAmB,CAAC;CAAG"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/peer-discovery/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAA;AACpD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAErD;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,aAAa,eAAuC,CAAA;AAEjE,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,WAAW,CAAC,QAAQ,CAAC,CAAA;CAC9B;AAED,MAAM,WAAW,aAAc,SAAQ,gBAAgB,CAAC,mBAAmB,CAAC;CAAG"}
@@ -1,5 +1,5 @@
1
1
  import type { Stream } from '../connection/index.js';
2
- import type { EventEmitter } from '../events.js';
2
+ import type { TypedEventTarget } from '../events.js';
3
3
  import type { PeerId } from '../peer-id/index.js';
4
4
  import type { Pushable } from 'it-pushable';
5
5
  import type { Uint8ArrayList } from 'uint8arraylist';
@@ -55,7 +55,7 @@ export interface PubSubRPC {
55
55
  subscriptions: PubSubRPCSubscription[];
56
56
  messages: PubSubRPCMessage[];
57
57
  }
58
- export interface PeerStreams extends EventEmitter<PeerStreamEvents> {
58
+ export interface PeerStreams extends TypedEventTarget<PeerStreamEvents> {
59
59
  id: PeerId;
60
60
  protocol: string;
61
61
  outboundStream?: Pushable<Uint8ArrayList>;
@@ -126,7 +126,7 @@ export declare enum TopicValidatorResult {
126
126
  export interface TopicValidatorFn {
127
127
  (peer: PeerId, message: Message): TopicValidatorResult | Promise<TopicValidatorResult>;
128
128
  }
129
- export interface PubSub<Events extends Record<string, any> = PubSubEvents> extends EventEmitter<Events> {
129
+ export interface PubSub<Events extends Record<string, any> = PubSubEvents> extends TypedEventTarget<Events> {
130
130
  /**
131
131
  * The global signature policy controls whether or not we sill send and receive
132
132
  * signed or unsigned messages.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/pubsub/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAA;AACpD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAChD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AACjD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AAC3C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAEpD;;;;;;;GAOG;AACH,eAAO,MAAM,UAAU,eAAe,CAAA;AAEtC;;;;;;;;;GASG;AACH,eAAO,MAAM,YAAY,iBAAiB,CAAA;AAE1C,MAAM,MAAM,eAAe,GAAG,OAAO,UAAU,GAAG,OAAO,YAAY,CAAA;AAErE,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,QAAQ,CAAA;IACd,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,UAAU,CAAA;IAChB,cAAc,EAAE,MAAM,CAAA;IACtB,SAAS,EAAE,UAAU,CAAA;IACrB,GAAG,EAAE,UAAU,CAAA;CAChB;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,UAAU,CAAA;IAChB,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,UAAU,CAAA;CACjB;AAED,MAAM,MAAM,OAAO,GAAG,aAAa,GAAG,eAAe,CAA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ACzG;;;;;;OAMG;IACH,qBAAqB,EAAE,OAAO,UAAU,GAAG,OAAO,YAAY,CAAA;IAE9D;;OAEG;IACH,WAAW,EAAE,MAAM,EAAE,CAAA;IAErB;;;;;;;;;;;;;;;;;;;OAmBG;IACH,eAAe,EAAE,GAAG,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAA;IAE9C,QAAQ,IAAI,MAAM,EAAE,CAAA;IAEpB;;;;;;OAMG;IACH,SAAS,IAAI,MAAM,EAAE,CAAA;IAErB;;;;;;;;;;;;;;;;OAgBG;IACH,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAA;IAE9B;;;;;;;;;;;;;;OAcG;IACH,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAA;IAEhC;;;;;;;;OAQG;IACH,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAEvC;;;;;;;;;;;OAWG;IACH,OAAO,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,GAAG,OAAO,CAAC,aAAa,CAAC,CAAA;CACjE;AAED,MAAM,WAAW,gBAAgB;IAC/B,gBAAgB,EAAE,WAAW,CAAC,KAAK,CAAC,CAAA;IACpC,iBAAiB,EAAE,WAAW,CAAC,KAAK,CAAC,CAAA;IACrC,OAAO,EAAE,WAAW,CAAC,KAAK,CAAC,CAAA;CAC5B"}
@@ -3,7 +3,20 @@ import type { PeerId } from '../peer-id/index.js';
3
3
  export interface Topology {
4
4
  min?: number;
5
5
  max?: number;
6
+ /**
7
+ * If true, invoke `onConnect` for this topology on transient (e.g. short-lived
8
+ * and/or data-limited) connections. (default: false)
9
+ */
10
+ notifyOnTransient?: boolean;
11
+ /**
12
+ * Invoked when a new connection is opened to a peer that supports the
13
+ * registered protocol
14
+ */
6
15
  onConnect?(peerId: PeerId, conn: Connection): void;
16
+ /**
17
+ * Invoked when the last connection to a peer that supports the registered
18
+ * protocol closes
19
+ */
7
20
  onDisconnect?(peerId: PeerId): void;
8
21
  }
9
22
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/topology/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAA;AACxD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AAEjD,MAAM,WAAW,QAAQ;IACvB,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,GAAG,CAAC,EAAE,MAAM,CAAA;IAEZ,SAAS,CAAC,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,GAAG,IAAI,CAAA;IAClD,YAAY,CAAC,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAA;CACpC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/topology/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAA;AACxD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AAEjD,MAAM,WAAW,QAAQ;IACvB,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,GAAG,CAAC,EAAE,MAAM,CAAA;IAEZ;;;OAGG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAE3B;;;OAGG;IACH,SAAS,CAAC,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,GAAG,IAAI,CAAA;IAElD;;;OAGG;IACH,YAAY,CAAC,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAA;CACpC"}
@@ -1,5 +1,5 @@
1
1
  import type { Connection, MultiaddrConnection } from '../connection/index.js';
2
- import type { EventEmitter } from '../events.js';
2
+ import type { TypedEventTarget } from '../events.js';
3
3
  import type { AbortOptions } from '../index.js';
4
4
  import type { StreamMuxerFactory } from '../stream-muxer/index.js';
5
5
  import type { Multiaddr } from '@multiformats/multiaddr';
@@ -9,7 +9,7 @@ export interface ListenerEvents {
9
9
  'error': CustomEvent<Error>;
10
10
  'close': CustomEvent;
11
11
  }
12
- export interface Listener extends EventEmitter<ListenerEvents> {
12
+ export interface Listener extends TypedEventTarget<ListenerEvents> {
13
13
  /**
14
14
  * Start a listener
15
15
  */
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/transport/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAA;AAC7E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAChD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAC/C,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAA;AAClE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAA;AAExD,MAAM,WAAW,cAAc;IAC7B,YAAY,EAAE,WAAW,CAAC,UAAU,CAAC,CAAA;IACrC,WAAW,EAAE,WAAW,CAAA;IACxB,OAAO,EAAE,WAAW,CAAC,KAAK,CAAC,CAAA;IAC3B,OAAO,EAAE,WAAW,CAAA;CACrB;AAED,MAAM,WAAW,QAAS,SAAQ,YAAY,CAAC,cAAc,CAAC;IAC5D;;OAEG;IACH,MAAM,CAAC,SAAS,EAAE,SAAS,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;IAC3C;;OAEG;IACH,QAAQ,IAAI,SAAS,EAAE,CAAA;IACvB;;;;OAIG;IACH,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC,CAAA;CACvB;AAED,eAAO,MAAM,MAAM,eAAkC,CAAA;AAErD,MAAM,WAAW,iBAAiB;IAAG,CAAC,UAAU,EAAE,UAAU,GAAG,IAAI,CAAA;CAAE;AAErE,MAAM,WAAW,eAAe;IAAG,CAAC,UAAU,EAAE,SAAS,EAAE,GAAG,SAAS,EAAE,CAAA;CAAE;AA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,CAAC,WAAW,CAAC,EAAE,MAAM,CAAA;IAE5B;;OAEG;IACH,CAAC,MAAM,CAAC,EAAE,IAAI,CAAA;IAEd;;OAEG;IACH,IAAI,CAAC,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,WAAW,GAAG,OAAO,CAAC,UAAU,CAAC,CAAA;IAE9D;;OAEG;IACH,cAAc,CAAC,OAAO,EAAE,qBAAqB,GAAG,QAAQ,CAAA;IAExD;;OAEG;IACH,MAAM,EAAE,eAAe,CAAA;CACxB;AAED,wBAAgB,WAAW,CAAE,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,SAAS,CAE3D;AAED;;GAEG;AACH,oBAAY,cAAc;IACxB;;OAEG;IACH,SAAS,IAAI;IAEb;;OAEG;IACH,QAAQ,IAAA;CACT;AAED,MAAM,WAAW,eAAe;IAC9B,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,YAAY,CAAC,EAAE,kBAAkB,CAAA;IAEjC;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB;AAED,MAAM,WAAW,QAAQ;IACvB;;OAEG;IACH,eAAe,CAAC,MAAM,EAAE,mBAAmB,EAAE,IAAI,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,UAAU,CAAC,CAAA;IAEzF;;OAEG;IACH,cAAc,CAAC,MAAM,EAAE,mBAAmB,EAAE,IAAI,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,UAAU,CAAC,CAAA;CACzF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@libp2p/interface",
3
- "version": "0.1.3",
3
+ "version": "0.1.4-16a87076",
4
4
  "description": "The interface implemented by a libp2p node",
5
5
  "license": "Apache-2.0 OR MIT",
6
6
  "homepage": "https://github.com/libp2p/js-libp2p/tree/master/packages/interface#readme",
@@ -39,6 +39,9 @@
39
39
  "!dist/test",
40
40
  "!**/*.tsbuildinfo"
41
41
  ],
42
+ "browser": {
43
+ "events": "./dist/src/events.browser.js"
44
+ },
42
45
  "exports": {
43
46
  ".": {
44
47
  "types": "./dist/src/index.d.ts",
@@ -173,7 +176,7 @@
173
176
  "delay": "^6.0.0",
174
177
  "it-all": "^3.0.3",
175
178
  "it-drain": "^3.0.3",
176
- "sinon": "^16.0.0",
177
- "sinon-ts": "^1.0.0"
179
+ "sinon": "^17.0.0",
180
+ "sinon-ts": "^2.0.0"
178
181
  }
179
182
  }
@@ -0,0 +1,2 @@
1
+ /** Noop for browser compatibility */
2
+ export function setMaxListeners (): void {}
package/src/events.ts CHANGED
@@ -1,3 +1,5 @@
1
+ import { setMaxListeners as nodeSetMaxListeners } from 'events'
2
+
1
3
  export interface EventCallback<EventType> { (evt: EventType): void }
2
4
  export interface EventObject<EventType> { handleEvent: EventCallback<EventType> }
3
5
  export type EventHandler<EventType> = EventCallback<EventType> | EventObject<EventType>
@@ -15,7 +17,23 @@ interface Listener {
15
17
  * https://github.com/microsoft/TypeScript/issues/299
16
18
  * etc
17
19
  */
18
- export class EventEmitter<EventMap extends Record<string, any>> extends EventTarget {
20
+ export interface TypedEventTarget <EventMap extends Record<string, any>> extends EventTarget {
21
+ addEventListener<K extends keyof EventMap>(type: K, listener: EventHandler<EventMap[K]> | null, options?: boolean | AddEventListenerOptions): void
22
+
23
+ listenerCount (type: string): number
24
+
25
+ removeEventListener<K extends keyof EventMap>(type: K, listener?: EventHandler<EventMap[K]> | null, options?: boolean | EventListenerOptions): void
26
+
27
+ removeEventListener (type: string, listener?: EventHandler<Event>, options?: boolean | EventListenerOptions): void
28
+
29
+ safeDispatchEvent<Detail>(type: keyof EventMap, detail: CustomEventInit<Detail>): boolean
30
+ }
31
+
32
+ /**
33
+ * An implementation of a typed event target
34
+ * etc
35
+ */
36
+ export class TypedEventEmitter<EventMap extends Record<string, any>> extends EventTarget implements TypedEventTarget<EventMap> {
19
37
  #listeners = new Map<any, Listener[]>()
20
38
 
21
39
  listenerCount (type: string): number {
@@ -98,3 +116,15 @@ class CustomEventPolyfill<T = any> extends Event {
98
116
  }
99
117
 
100
118
  export const CustomEvent = globalThis.CustomEvent ?? CustomEventPolyfill
119
+
120
+ // TODO: remove this in v1
121
+ export { TypedEventEmitter as EventEmitter }
122
+
123
+ // create a setMaxListeners that doesn't break browser usage
124
+ export const setMaxListeners: typeof nodeSetMaxListeners = (n, ...eventTargets) => {
125
+ try {
126
+ nodeSetMaxListeners(n, ...eventTargets)
127
+ } catch {
128
+ // swallow error, gulp
129
+ }
130
+ }
package/src/index.ts CHANGED
@@ -16,7 +16,7 @@
16
16
 
17
17
  import type { Connection, NewStreamOptions, Stream } from './connection/index.js'
18
18
  import type { ContentRouting } from './content-routing/index.js'
19
- import type { EventEmitter } from './events.js'
19
+ import type { TypedEventTarget } from './events.js'
20
20
  import type { KeyChain } from './keychain/index.js'
21
21
  import type { Metrics } from './metrics/index.js'
22
22
  import type { PeerId } from './peer-id/index.js'
@@ -99,6 +99,11 @@ export interface IdentifyResult {
99
99
  * If sent by the remote peer this is the deserialized signed peer record
100
100
  */
101
101
  signedPeerRecord?: SignedPeerRecord
102
+
103
+ /**
104
+ * The connection that the identify protocol ran over
105
+ */
106
+ connection: Connection
102
107
  }
103
108
 
104
109
  /**
@@ -303,7 +308,7 @@ export interface PendingDial {
303
308
  /**
304
309
  * Libp2p nodes implement this interface.
305
310
  */
306
- export interface Libp2p<T extends ServiceMap = ServiceMap> extends Startable, EventEmitter<Libp2pEvents<T>> {
311
+ export interface Libp2p<T extends ServiceMap = ServiceMap> extends Startable, TypedEventTarget<Libp2pEvents<T>> {
307
312
  /**
308
313
  * The PeerId is a unique identifier for a node on the network.
309
314
  *
@@ -1,4 +1,4 @@
1
- import type { EventEmitter } from '../events.js'
1
+ import type { TypedEventTarget } from '../events.js'
2
2
  import type { PeerInfo } from '../peer-info/index.js'
3
3
 
4
4
  /**
@@ -26,4 +26,4 @@ export interface PeerDiscoveryEvents {
26
26
  'peer': CustomEvent<PeerInfo>
27
27
  }
28
28
 
29
- export interface PeerDiscovery extends EventEmitter<PeerDiscoveryEvents> {}
29
+ export interface PeerDiscovery extends TypedEventTarget<PeerDiscoveryEvents> {}
@@ -1,5 +1,5 @@
1
1
  import type { Stream } from '../connection/index.js'
2
- import type { EventEmitter } from '../events.js'
2
+ import type { TypedEventTarget } from '../events.js'
3
3
  import type { PeerId } from '../peer-id/index.js'
4
4
  import type { Pushable } from 'it-pushable'
5
5
  import type { Uint8ArrayList } from 'uint8arraylist'
@@ -65,7 +65,7 @@ export interface PubSubRPC {
65
65
  messages: PubSubRPCMessage[]
66
66
  }
67
67
 
68
- export interface PeerStreams extends EventEmitter<PeerStreamEvents> {
68
+ export interface PeerStreams extends TypedEventTarget<PeerStreamEvents> {
69
69
  id: PeerId
70
70
  protocol: string
71
71
  outboundStream?: Pushable<Uint8ArrayList>
@@ -152,7 +152,7 @@ export interface TopicValidatorFn {
152
152
  (peer: PeerId, message: Message): TopicValidatorResult | Promise<TopicValidatorResult>
153
153
  }
154
154
 
155
- export interface PubSub<Events extends Record<string, any> = PubSubEvents> extends EventEmitter<Events> {
155
+ export interface PubSub<Events extends Record<string, any> = PubSubEvents> extends TypedEventTarget<Events> {
156
156
  /**
157
157
  * The global signature policy controls whether or not we sill send and receive
158
158
  * signed or unsigned messages.
@@ -5,6 +5,21 @@ export interface Topology {
5
5
  min?: number
6
6
  max?: number
7
7
 
8
+ /**
9
+ * If true, invoke `onConnect` for this topology on transient (e.g. short-lived
10
+ * and/or data-limited) connections. (default: false)
11
+ */
12
+ notifyOnTransient?: boolean
13
+
14
+ /**
15
+ * Invoked when a new connection is opened to a peer that supports the
16
+ * registered protocol
17
+ */
8
18
  onConnect?(peerId: PeerId, conn: Connection): void
19
+
20
+ /**
21
+ * Invoked when the last connection to a peer that supports the registered
22
+ * protocol closes
23
+ */
9
24
  onDisconnect?(peerId: PeerId): void
10
25
  }
@@ -1,5 +1,5 @@
1
1
  import type { Connection, MultiaddrConnection } from '../connection/index.js'
2
- import type { EventEmitter } from '../events.js'
2
+ import type { TypedEventTarget } from '../events.js'
3
3
  import type { AbortOptions } from '../index.js'
4
4
  import type { StreamMuxerFactory } from '../stream-muxer/index.js'
5
5
  import type { Multiaddr } from '@multiformats/multiaddr'
@@ -11,7 +11,7 @@ export interface ListenerEvents {
11
11
  'close': CustomEvent
12
12
  }
13
13
 
14
- export interface Listener extends EventEmitter<ListenerEvents> {
14
+ export interface Listener extends TypedEventTarget<ListenerEvents> {
15
15
  /**
16
16
  * Start a listener
17
17
  */
@@ -1,258 +0,0 @@
1
- {
2
- "Connection": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.Connection.html",
3
- "./connection:Connection": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.Connection.html",
4
- "ConnectionProtector": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.ConnectionProtector.html",
5
- "./connection:ConnectionProtector": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.ConnectionProtector.html",
6
- "ConnectionTimeline": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.ConnectionTimeline.html",
7
- "./connection:ConnectionTimeline": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.ConnectionTimeline.html",
8
- "MultiaddrConnection": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.MultiaddrConnection.html",
9
- "./connection:MultiaddrConnection": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.MultiaddrConnection.html",
10
- "MultiaddrConnectionTimeline": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.MultiaddrConnectionTimeline.html",
11
- "./connection:MultiaddrConnectionTimeline": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.MultiaddrConnectionTimeline.html",
12
- "NewStreamOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.NewStreamOptions.html",
13
- "./connection:NewStreamOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.NewStreamOptions.html",
14
- "Stream": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.Stream.html",
15
- "./connection:Stream": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.Stream.html",
16
- "StreamTimeline": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.StreamTimeline.html",
17
- "./connection:StreamTimeline": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection.StreamTimeline.html",
18
- "ConnectionStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.ConnectionStatus.html",
19
- "./connection:ConnectionStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.ConnectionStatus.html",
20
- "Direction": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.Direction.html",
21
- "./connection:Direction": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.Direction.html",
22
- "ReadStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.ReadStatus.html",
23
- "./connection:ReadStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.ReadStatus.html",
24
- "StreamStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.StreamStatus.html",
25
- "./connection:StreamStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.StreamStatus.html",
26
- "WriteStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.WriteStatus.html",
27
- "./connection:WriteStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.connection.WriteStatus.html",
28
- "symbol": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.connection.symbol.html",
29
- "./connection:symbol": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.connection.symbol.html",
30
- "isConnection": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.connection.isConnection.html",
31
- "./connection:isConnection": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.connection.isConnection.html",
32
- "ConnectionEncrypter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection_encrypter.ConnectionEncrypter.html",
33
- "./connection-encrypter:ConnectionEncrypter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection_encrypter.ConnectionEncrypter.html",
34
- "SecuredConnection": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection_encrypter.SecuredConnection.html",
35
- "./connection-encrypter:SecuredConnection": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection_encrypter.SecuredConnection.html",
36
- "ConnectionGater": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection_gater.ConnectionGater.html",
37
- "./connection-gater:ConnectionGater": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.connection_gater.ConnectionGater.html",
38
- "ContentRouting": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.content_routing.ContentRouting.html",
39
- "./content-routing:ContentRouting": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.content_routing.ContentRouting.html",
40
- "contentRouting": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.content_routing.contentRouting-1.html",
41
- "./content-routing:contentRouting": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.content_routing.contentRouting-1.html",
42
- "AbortError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.AbortError.html",
43
- "./errors:AbortError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.AbortError.html",
44
- "CodeError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.CodeError.html",
45
- "./errors:CodeError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.CodeError.html",
46
- "InvalidCryptoExchangeError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.InvalidCryptoExchangeError.html",
47
- "./errors:InvalidCryptoExchangeError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.InvalidCryptoExchangeError.html",
48
- "InvalidCryptoTransmissionError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.InvalidCryptoTransmissionError.html",
49
- "./errors:InvalidCryptoTransmissionError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.InvalidCryptoTransmissionError.html",
50
- "UnexpectedPeerError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.UnexpectedPeerError.html",
51
- "./errors:UnexpectedPeerError": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.errors.UnexpectedPeerError.html",
52
- "EventEmitter": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.events.EventEmitter.html",
53
- "./events:EventEmitter": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.events.EventEmitter.html",
54
- "EventCallback": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.events.EventCallback.html",
55
- "./events:EventCallback": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.events.EventCallback.html",
56
- "EventObject": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.events.EventObject.html",
57
- "./events:EventObject": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.events.EventObject.html",
58
- "EventHandler": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.events.EventHandler.html",
59
- "./events:EventHandler": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.events.EventHandler.html",
60
- "CustomEvent": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.events.CustomEvent.html",
61
- "./events:CustomEvent": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.events.CustomEvent.html",
62
- "AbortOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.AbortOptions.html",
63
- ".:AbortOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.AbortOptions.html",
64
- "AddressSorter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.AddressSorter.html",
65
- ".:AddressSorter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.AddressSorter.html",
66
- "IdentifyResult": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.IdentifyResult.html",
67
- ".:IdentifyResult": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.IdentifyResult.html",
68
- "Libp2p": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.Libp2p.html",
69
- ".:Libp2p": "https://libp2p.github.io/js-libp2p/interfaces/libp2p.index.Libp2p.html",
70
- "Libp2pEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.Libp2pEvents.html",
71
- ".:Libp2pEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.Libp2pEvents.html",
72
- "PeerUpdate": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.PeerUpdate.html",
73
- ".:PeerUpdate": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.PeerUpdate.html",
74
- "PendingDial": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.PendingDial.html",
75
- ".:PendingDial": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.PendingDial.html",
76
- "SignedPeerRecord": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.SignedPeerRecord.html",
77
- ".:SignedPeerRecord": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.index.SignedPeerRecord.html",
78
- "PendingDialStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.index.PendingDialStatus.html",
79
- ".:PendingDialStatus": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.index.PendingDialStatus.html",
80
- "RecursivePartial": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.index.RecursivePartial.html",
81
- ".:RecursivePartial": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.index.RecursivePartial.html",
82
- "ServiceMap": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.index.ServiceMap.html",
83
- ".:ServiceMap": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.index.ServiceMap.html",
84
- "KeyChain": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keychain.KeyChain.html",
85
- "./keychain:KeyChain": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keychain.KeyChain.html",
86
- "KeyInfo": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keychain.KeyInfo.html",
87
- "./keychain:KeyInfo": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keychain.KeyInfo.html",
88
- "PrivateKey": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keys.PrivateKey.html",
89
- "./keys:PrivateKey": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keys.PrivateKey.html",
90
- "PublicKey": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keys.PublicKey.html",
91
- "./keys:PublicKey": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.keys.PublicKey.html",
92
- "KeyType": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.keys.KeyType.html",
93
- "./keys:KeyType": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.keys.KeyType.html",
94
- "Ed25519": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.keys.Ed25519.html",
95
- "./keys:Ed25519": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.keys.Ed25519.html",
96
- "RSA": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.keys.RSA.html",
97
- "./keys:RSA": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.keys.RSA.html",
98
- "secp256k1": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.keys.secp256k1.html",
99
- "./keys:secp256k1": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.keys.secp256k1.html",
100
- "CalculatedMetricOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.CalculatedMetricOptions.html",
101
- "./metrics:CalculatedMetricOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.CalculatedMetricOptions.html",
102
- "Counter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.Counter.html",
103
- "./metrics:Counter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.Counter.html",
104
- "CounterGroup": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.CounterGroup.html",
105
- "./metrics:CounterGroup": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.CounterGroup.html",
106
- "Metric": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.Metric.html",
107
- "./metrics:Metric": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.Metric.html",
108
- "MetricGroup": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.MetricGroup.html",
109
- "./metrics:MetricGroup": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.MetricGroup.html",
110
- "MetricOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.MetricOptions.html",
111
- "./metrics:MetricOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.MetricOptions.html",
112
- "Metrics": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.Metrics.html",
113
- "./metrics:Metrics": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.Metrics.html",
114
- "StopTimer": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.StopTimer.html",
115
- "./metrics:StopTimer": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics.StopTimer.html",
116
- "CalculateMetric": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.metrics.CalculateMetric.html",
117
- "./metrics:CalculateMetric": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.metrics.CalculateMetric.html",
118
- "CreateTrackedMapInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics_tracked_map.CreateTrackedMapInit.html",
119
- "./metrics/tracked-map:CreateTrackedMapInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics_tracked_map.CreateTrackedMapInit.html",
120
- "TrackedMapInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics_tracked_map.TrackedMapInit.html",
121
- "./metrics/tracked-map:TrackedMapInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.metrics_tracked_map.TrackedMapInit.html",
122
- "trackedMap": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.metrics_tracked_map.trackedMap.html",
123
- "./metrics/tracked-map:trackedMap": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.metrics_tracked_map.trackedMap.html",
124
- "PeerDiscovery": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_discovery.PeerDiscovery.html",
125
- "./peer-discovery:PeerDiscovery": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_discovery.PeerDiscovery.html",
126
- "PeerDiscoveryEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_discovery.PeerDiscoveryEvents.html",
127
- "./peer-discovery:PeerDiscoveryEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_discovery.PeerDiscoveryEvents.html",
128
- "peerDiscovery": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.peer_discovery.peerDiscovery-1.html",
129
- "./peer-discovery:peerDiscovery": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.peer_discovery.peerDiscovery-1.html",
130
- "Ed25519PeerId": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_id.Ed25519PeerId.html",
131
- "./peer-id:Ed25519PeerId": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_id.Ed25519PeerId.html",
132
- "RSAPeerId": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_id.RSAPeerId.html",
133
- "./peer-id:RSAPeerId": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_id.RSAPeerId.html",
134
- "Secp256k1PeerId": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_id.Secp256k1PeerId.html",
135
- "./peer-id:Secp256k1PeerId": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_id.Secp256k1PeerId.html",
136
- "PeerId": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.peer_id.PeerId.html",
137
- "./peer-id:PeerId": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.peer_id.PeerId.html",
138
- "PeerIdType": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.peer_id.PeerIdType.html",
139
- "./peer-id:PeerIdType": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.peer_id.PeerIdType.html",
140
- "./peer-id:symbol": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.peer_id.symbol.html",
141
- "isPeerId": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.peer_id.isPeerId.html",
142
- "./peer-id:isPeerId": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.peer_id.isPeerId.html",
143
- "PeerInfo": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_info.PeerInfo.html",
144
- "./peer-info:PeerInfo": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_info.PeerInfo.html",
145
- "PeerRouting": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_routing.PeerRouting.html",
146
- "./peer-routing:PeerRouting": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_routing.PeerRouting.html",
147
- "peerRouting": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.peer_routing.peerRouting-1.html",
148
- "./peer-routing:peerRouting": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.peer_routing.peerRouting-1.html",
149
- "Address": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.Address.html",
150
- "./peer-store:Address": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.Address.html",
151
- "Peer": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.Peer.html",
152
- "./peer-store:Peer": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.Peer.html",
153
- "PeerData": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerData.html",
154
- "./peer-store:PeerData": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerData.html",
155
- "PeerQuery": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerQuery.html",
156
- "./peer-store:PeerQuery": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerQuery.html",
157
- "PeerQueryFilter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerQueryFilter.html",
158
- "./peer-store:PeerQueryFilter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerQueryFilter.html",
159
- "PeerQueryOrder": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerQueryOrder.html",
160
- "./peer-store:PeerQueryOrder": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerQueryOrder.html",
161
- "PeerStore": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerStore.html",
162
- "./peer-store:PeerStore": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.PeerStore.html",
163
- "Tag": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.Tag.html",
164
- "./peer-store:Tag": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.Tag.html",
165
- "TagOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.TagOptions.html",
166
- "./peer-store:TagOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.peer_store.TagOptions.html",
167
- "KEEP_ALIVE": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.peer_store_tags.KEEP_ALIVE.html",
168
- "./peer-store/tags:KEEP_ALIVE": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.peer_store_tags.KEEP_ALIVE.html",
169
- "TopicValidatorResult": "https://libp2p.github.io/js-libp2p/enums/_libp2p_interface.pubsub.TopicValidatorResult.html",
170
- "./pubsub:TopicValidatorResult": "https://libp2p.github.io/js-libp2p/enums/_libp2p_interface.pubsub.TopicValidatorResult.html",
171
- "PeerStreamEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PeerStreamEvents.html",
172
- "./pubsub:PeerStreamEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PeerStreamEvents.html",
173
- "PeerStreams": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PeerStreams.html",
174
- "./pubsub:PeerStreams": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PeerStreams.html",
175
- "PubSub": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSub.html",
176
- "./pubsub:PubSub": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSub.html",
177
- "PubSubEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubEvents.html",
178
- "./pubsub:PubSubEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubEvents.html",
179
- "PubSubInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubInit.html",
180
- "./pubsub:PubSubInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubInit.html",
181
- "PubSubRPC": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubRPC.html",
182
- "./pubsub:PubSubRPC": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubRPC.html",
183
- "PubSubRPCMessage": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubRPCMessage.html",
184
- "./pubsub:PubSubRPCMessage": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubRPCMessage.html",
185
- "PubSubRPCSubscription": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubRPCSubscription.html",
186
- "./pubsub:PubSubRPCSubscription": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PubSubRPCSubscription.html",
187
- "PublishResult": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PublishResult.html",
188
- "./pubsub:PublishResult": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.PublishResult.html",
189
- "SignedMessage": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.SignedMessage.html",
190
- "./pubsub:SignedMessage": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.SignedMessage.html",
191
- "SubscriptionChangeData": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.SubscriptionChangeData.html",
192
- "./pubsub:SubscriptionChangeData": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.SubscriptionChangeData.html",
193
- "TopicValidatorFn": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.TopicValidatorFn.html",
194
- "./pubsub:TopicValidatorFn": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.TopicValidatorFn.html",
195
- "UnsignedMessage": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.UnsignedMessage.html",
196
- "./pubsub:UnsignedMessage": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.pubsub.UnsignedMessage.html",
197
- "Message": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.pubsub.Message.html",
198
- "./pubsub:Message": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.pubsub.Message.html",
199
- "SignaturePolicy": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.pubsub.SignaturePolicy.html",
200
- "./pubsub:SignaturePolicy": "https://libp2p.github.io/js-libp2p/types/_libp2p_interface.pubsub.SignaturePolicy.html",
201
- "StrictNoSign": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.pubsub.StrictNoSign.html",
202
- "./pubsub:StrictNoSign": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.pubsub.StrictNoSign.html",
203
- "StrictSign": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.pubsub.StrictSign.html",
204
- "./pubsub:StrictSign": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.pubsub.StrictSign.html",
205
- "Envelope": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.record.Envelope.html",
206
- "./record:Envelope": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.record.Envelope.html",
207
- "Record": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.record.Record.html",
208
- "./record:Record": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.record.Record.html",
209
- "Startable": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.startable.Startable.html",
210
- "./startable:Startable": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.startable.Startable.html",
211
- "isStartable": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.startable.isStartable.html",
212
- "./startable:isStartable": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.startable.isStartable.html",
213
- "start": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.startable.start.html",
214
- "./startable:start": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.startable.start.html",
215
- "stop": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.startable.stop.html",
216
- "./startable:stop": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.startable.stop.html",
217
- "IncomingStreamData": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.IncomingStreamData.html",
218
- "./stream-handler:IncomingStreamData": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.IncomingStreamData.html",
219
- "StreamHandler": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.StreamHandler.html",
220
- "./stream-handler:StreamHandler": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.StreamHandler.html",
221
- "StreamHandlerOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.StreamHandlerOptions.html",
222
- "./stream-handler:StreamHandlerOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.StreamHandlerOptions.html",
223
- "StreamHandlerRecord": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.StreamHandlerRecord.html",
224
- "./stream-handler:StreamHandlerRecord": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_handler.StreamHandlerRecord.html",
225
- "StreamMuxer": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer.StreamMuxer.html",
226
- "./stream-muxer:StreamMuxer": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer.StreamMuxer.html",
227
- "StreamMuxerFactory": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer.StreamMuxerFactory.html",
228
- "./stream-muxer:StreamMuxerFactory": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer.StreamMuxerFactory.html",
229
- "StreamMuxerInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer.StreamMuxerInit.html",
230
- "./stream-muxer:StreamMuxerInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer.StreamMuxerInit.html",
231
- "AbstractStream": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.stream_muxer_stream.AbstractStream.html",
232
- "./stream-muxer/stream:AbstractStream": "https://libp2p.github.io/js-libp2p/classes/_libp2p_interface.stream_muxer_stream.AbstractStream.html",
233
- "AbstractStreamInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer_stream.AbstractStreamInit.html",
234
- "./stream-muxer/stream:AbstractStreamInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.stream_muxer_stream.AbstractStreamInit.html",
235
- "FaultTolerance": "https://libp2p.github.io/js-libp2p/enums/_libp2p_interface.transport.FaultTolerance.html",
236
- "./transport:FaultTolerance": "https://libp2p.github.io/js-libp2p/enums/_libp2p_interface.transport.FaultTolerance.html",
237
- "ConnectionHandler": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.ConnectionHandler.html",
238
- "./transport:ConnectionHandler": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.ConnectionHandler.html",
239
- "CreateListenerOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.CreateListenerOptions.html",
240
- "./transport:CreateListenerOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.CreateListenerOptions.html",
241
- "DialOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.DialOptions.html",
242
- "./transport:DialOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.DialOptions.html",
243
- "Listener": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.Listener.html",
244
- "./transport:Listener": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.Listener.html",
245
- "ListenerEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.ListenerEvents.html",
246
- "./transport:ListenerEvents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.ListenerEvents.html",
247
- "MultiaddrFilter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.MultiaddrFilter.html",
248
- "./transport:MultiaddrFilter": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.MultiaddrFilter.html",
249
- "Transport": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.Transport.html",
250
- "./transport:Transport": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.Transport.html",
251
- "Upgrader": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.Upgrader.html",
252
- "./transport:Upgrader": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.Upgrader.html",
253
- "UpgraderOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.UpgraderOptions.html",
254
- "./transport:UpgraderOptions": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_interface.transport.UpgraderOptions.html",
255
- "./transport:symbol": "https://libp2p.github.io/js-libp2p/variables/_libp2p_interface.transport.symbol.html",
256
- "isTransport": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.transport.isTransport.html",
257
- "./transport:isTransport": "https://libp2p.github.io/js-libp2p/functions/_libp2p_interface.transport.isTransport.html"
258
- }