mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 00:23:30 +01:00
fix(Gateway): Export interface (#10060)
* fix(types): export missing `Gateway` interface * docs(Gateway): update link to `WebSocketManager`
This commit is contained in:
@@ -2,6 +2,11 @@ import type { Awaitable } from '@discordjs/util';
|
||||
import type { ManagerShardEventsMap, WebSocketShardEvents } from '@discordjs/ws';
|
||||
import type { GatewaySendPayload } from 'discord-api-types/v10';
|
||||
|
||||
/**
|
||||
* Gateway-like structure that can be used to interact with an actual WebSocket connection.
|
||||
* You can provide a custom implementation, useful for running a message broker between your app and your gateway,
|
||||
* or you can simply use the {@link @discordjs/ws#(WebSocketManager:class)}.
|
||||
*/
|
||||
export interface Gateway {
|
||||
getShardCount(): Awaitable<number>;
|
||||
on(
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
export * from './api/index.js';
|
||||
export * from './client.js';
|
||||
export * from './Gateway.js';
|
||||
export * from './util/index.js';
|
||||
|
||||
export * from 'discord-api-types/v10';
|
||||
|
||||
Reference in New Issue
Block a user