mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 10:03:31 +01:00
feat(api-extractor): support multiple entrypoints (#10829)
* feat(api-extractor): support multiple entrypoints * chore: initial support in generateSplitDocumentation * chore: bring in line with upstream * refactor: multiple entrypoints in scripts * fix: split docs * feat: website * fix: docs failing on next * fix: don't include dtypes for now * refactor: don't fetch entrypoint if there is none --------- Co-authored-by: iCrawl <buechler.noel@outlook.com>
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import type { Awaitable } from '@discordjs/util';
|
||||
import type { IIdentifyThrottler } from '../../throttling/IIdentifyThrottler.js';
|
||||
import type { SessionInfo, WebSocketManager } from '../../ws/WebSocketManager.js';
|
||||
import type { FetchingStrategyOptions, IContextFetchingStrategy } from './IContextFetchingStrategy.js';
|
||||
@@ -28,7 +29,7 @@ export class SimpleContextFetchingStrategy implements IContextFetchingStrategy {
|
||||
return this.manager.options.retrieveSessionInfo(shardId);
|
||||
}
|
||||
|
||||
public updateSessionInfo(shardId: number, sessionInfo: SessionInfo | null) {
|
||||
public updateSessionInfo(shardId: number, sessionInfo: SessionInfo | null): Awaitable<void> {
|
||||
return this.manager.options.updateSessionInfo(shardId, sessionInfo);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import type { Collection } from '@discordjs/collection';
|
||||
import type { REST } from '@discordjs/rest';
|
||||
import { range, type Awaitable } from '@discordjs/util';
|
||||
import { AsyncEventEmitter } from '@vladfrangu/async_event_emitter';
|
||||
@@ -15,7 +16,7 @@ import {
|
||||
import type { IShardingStrategy } from '../strategies/sharding/IShardingStrategy.js';
|
||||
import type { IIdentifyThrottler } from '../throttling/IIdentifyThrottler.js';
|
||||
import { DefaultWebSocketManagerOptions, type CompressionMethod, type Encoding } from '../utils/constants.js';
|
||||
import type { WebSocketShardDestroyOptions, WebSocketShardEvents } from './WebSocketShard.js';
|
||||
import type { WebSocketShardDestroyOptions, WebSocketShardEvents, WebSocketShardStatus } from './WebSocketShard.js';
|
||||
|
||||
/**
|
||||
* Represents a range of shard ids
|
||||
@@ -400,7 +401,7 @@ export class WebSocketManager extends AsyncEventEmitter<ManagerShardEventsMap> i
|
||||
return this.strategy.send(shardId, payload);
|
||||
}
|
||||
|
||||
public fetchStatus() {
|
||||
public fetchStatus(): Awaitable<Collection<number, WebSocketShardStatus>> {
|
||||
return this.strategy.fetchStatus();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user