Skip to content

Commit d92e52e

Browse files
committed
docs: export all visible symbols
1 parent e3e3c21 commit d92e52e

File tree

11 files changed

+39
-28
lines changed

11 files changed

+39
-28
lines changed

packages/brokers/src/brokers/redis/RPCRedis.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import type { IRPCBroker } from '../Broker.js';
55
import type { RedisBrokerOptions } from './BaseRedis.js';
66
import { BaseRedisBroker, DefaultRedisBrokerOptions } from './BaseRedis.js';
77

8-
interface InternalPromise {
8+
export interface InternalPromise {
99
reject(error: any): void;
1010
resolve(data: any): void;
1111
timeout: NodeJS.Timeout;

packages/builders/src/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export * from './messages/embed/EmbedFooter.js';
6262

6363
export * from './util/componentUtil.js';
6464
export * from './util/normalizeArray.js';
65-
export * from './util/validation.js';
65+
export { disableValidators, enableValidators, isValidationEnabled } from './util/validation.js';
6666

6767
export * from './Assertions.js';
6868

packages/collection/src/collection.ts

-6
Original file line numberDiff line numberDiff line change
@@ -1094,12 +1094,6 @@ export class Collection<Key, Value> extends Map<Key, Value> {
10941094
declare public static readonly [Symbol.species]: typeof Collection;
10951095
}
10961096

1097-
/**
1098-
* @internal
1099-
*/
11001097
export type Keep<Value> = { keep: false } | { keep: true; value: Value };
11011098

1102-
/**
1103-
* @internal
1104-
*/
11051099
export type Comparator<Key, Value> = (firstValue: Value, secondValue: Value, firstKey: Key, secondKey: Key) => number;

packages/rest/src/lib/errors/DiscordAPIError.ts

+7-3
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
11
import type { InternalRequest, RawFile } from '../utils/types.js';
22

3-
interface DiscordErrorFieldInformation {
3+
export interface DiscordErrorFieldInformation {
44
code: string;
55
message: string;
66
}
77

8-
interface DiscordErrorGroupWrapper {
8+
export interface DiscordErrorGroupWrapper {
99
_errors: DiscordError[];
1010
}
1111

12-
type DiscordError = DiscordErrorFieldInformation | DiscordErrorGroupWrapper | string | { [k: string]: DiscordError };
12+
export type DiscordError =
13+
| DiscordErrorFieldInformation
14+
| DiscordErrorGroupWrapper
15+
| string
16+
| { [k: string]: DiscordError };
1317

1418
export interface DiscordErrorData {
1519
code: number;

packages/rest/src/lib/utils/types.ts

-6
Original file line numberDiff line numberDiff line change
@@ -362,8 +362,6 @@ export type RouteLike = `/${string}`;
362362

363363
/**
364364
* Internal request options
365-
*
366-
* @internal
367365
*/
368366
export interface InternalRequest extends RequestData {
369367
fullRoute: RouteLike;
@@ -376,8 +374,6 @@ export interface HandlerRequestData extends Pick<InternalRequest, 'body' | 'file
376374

377375
/**
378376
* Parsed route data for an endpoint
379-
*
380-
* @internal
381377
*/
382378
export interface RouteData {
383379
bucketRoute: string;
@@ -387,8 +383,6 @@ export interface RouteData {
387383

388384
/**
389385
* Represents a hash and its associated fields
390-
*
391-
* @internal
392386
*/
393387
export interface HashData {
394388
lastAccess: number;

packages/rest/src/shared.ts

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ export * from './lib/CDN.js';
22
export * from './lib/errors/DiscordAPIError.js';
33
export * from './lib/errors/HTTPError.js';
44
export * from './lib/errors/RateLimitError.js';
5+
export * from './lib/interfaces/Handler.js';
56
export * from './lib/REST.js';
67
export * from './lib/utils/constants.js';
78
export * from './lib/utils/types.js';

packages/voice/src/VoiceConnection.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -272,14 +272,14 @@ export class VoiceConnection extends EventEmitter {
272272

273273
/**
274274
* The current state of the voice connection.
275+
*
276+
* @remarks
277+
* The setter will perform clean-up operations where necessary.
275278
*/
276279
public get state() {
277280
return this._state;
278281
}
279282

280-
/**
281-
* Updates the state of the voice connection, performing clean-up operations where necessary.
282-
*/
283283
public set state(newState: VoiceConnectionState) {
284284
const oldState = this._state;
285285
const oldNetworking = Reflect.get(oldState, 'networking') as Networking | undefined;

packages/voice/src/audio/AudioPlayer.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -304,14 +304,14 @@ export class AudioPlayer extends EventEmitter {
304304

305305
/**
306306
* The state that the player is in.
307+
*
308+
* @remarks
309+
* The setter will perform clean-up operations when transitioning between states.
307310
*/
308311
public get state() {
309312
return this._state;
310313
}
311314

312-
/**
313-
* Sets a new state for the player, performing clean-up operations where necessary.
314-
*/
315315
public set state(newState: AudioPlayerState) {
316316
const oldState = this._state;
317317
const newResource = Reflect.get(newState, 'resource') as AudioResource | undefined;

packages/voice/src/audio/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ export { AudioResource, type CreateAudioResourceOptions, createAudioResource } f
1717

1818
export { PlayerSubscription } from './PlayerSubscription';
1919

20-
export { StreamType } from './TransformerGraph';
20+
export { StreamType, type Edge, TransformerType, Node } from './TransformerGraph';

packages/voice/src/index.ts

+18
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,24 @@ export * from './audio/index';
33
export * from './util/index';
44
export * from './receive/index';
55

6+
export {
7+
Networking,
8+
type ConnectionData,
9+
type ConnectionOptions,
10+
type NetworkingState,
11+
type NetworkingResumingState,
12+
type NetworkingSelectingProtocolState,
13+
type NetworkingUdpHandshakingState,
14+
type NetworkingClosedState,
15+
type NetworkingIdentifyingState,
16+
type NetworkingOpeningWsState,
17+
type NetworkingReadyState,
18+
NetworkingStatusCode,
19+
VoiceUDPSocket,
20+
VoiceWebSocket,
21+
type SocketConfig,
22+
} from './networking/index.js';
23+
624
export {
725
VoiceConnection,
826
type VoiceConnectionState,

packages/voice/src/networking/Networking.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ export type NetworkingState =
131131
* are first received on the main bot gateway, in the form of VOICE_SERVER_UPDATE
132132
* and VOICE_STATE_UPDATE packets.
133133
*/
134-
interface ConnectionOptions {
134+
export interface ConnectionOptions {
135135
endpoint: string;
136136
serverId: string;
137137
sessionId: string;
@@ -254,14 +254,14 @@ export class Networking extends EventEmitter {
254254

255255
/**
256256
* The current state of the networking instance.
257+
*
258+
* @remarks
259+
* The setter will perform clean-up operations where necessary.
257260
*/
258261
public get state(): NetworkingState {
259262
return this._state;
260263
}
261264

262-
/**
263-
* Sets a new state for the networking instance, performing clean-up operations where necessary.
264-
*/
265265
public set state(newState: NetworkingState) {
266266
const oldWs = Reflect.get(this._state, 'ws') as VoiceWebSocket | undefined;
267267
const newWs = Reflect.get(newState, 'ws') as VoiceWebSocket | undefined;

0 commit comments

Comments
 (0)