Expose types to ensure documentation is complete

This commit is contained in:
Franck Royer 2022-01-13 16:09:01 +11:00
parent 6276b1537f
commit b65ab17cb9
No known key found for this signature in database
GPG Key ID: A82ED75A8DFC50A4
4 changed files with 6 additions and 5 deletions

View File

@ -9,7 +9,7 @@ import { ENRTree } from './enrtree';
const dbg = debug('waku:discovery:dns'); const dbg = debug('waku:discovery:dns');
type SearchContext = { export type SearchContext = {
domain: string; domain: string;
publicKey: string; publicKey: string;
visits: { [key: string]: boolean }; visits: { [key: string]: boolean };

View File

@ -7,14 +7,14 @@ import { ecdsaVerify } from 'secp256k1';
import { ENR } from '../enr'; import { ENR } from '../enr';
import { keccak256Buf } from '../utils'; import { keccak256Buf } from '../utils';
type ENRRootValues = { export type ENRRootValues = {
eRoot: string; eRoot: string;
lRoot: string; lRoot: string;
seq: number; seq: number;
signature: string; signature: string;
}; };
type ENRTreeValues = { export type ENRTreeValues = {
publicKey: string; publicKey: string;
domain: string; domain: string;
}; };

View File

@ -2,9 +2,9 @@ import { shuffle } from 'libp2p-gossipsub/src/utils';
export { getNodesFromHostedJson } from './hosted_json'; export { getNodesFromHostedJson } from './hosted_json';
export { Bootstrap, BootstrapOptions } from './bootstrap'; export { Bootstrap, BootstrapOptions } from './bootstrap';
export { DnsClient, DnsNodeDiscovery } from './dns'; export { DnsClient, DnsNodeDiscovery, SearchContext } from './dns';
export { Endpoints, DnsOverHttps } from './dns_over_https'; export { Endpoints, DnsOverHttps } from './dns_over_https';
export { ENRTree } from './enrtree'; export { ENRTree, ENRTreeValues, ENRRootValues } from './enrtree';
export function getPseudoRandomSubset<T>( export function getPseudoRandomSubset<T>(
values: T[], values: T[],

View File

@ -4,3 +4,4 @@ export * from './constants';
export * from './enr'; export * from './enr';
export * from './types'; export * from './types';
export * from './create'; export * from './create';
export * from './keypair';