This should allow for not using the `Client.channelGuildMap`,
`Client.threadGuildMap`, and `Client.guildShardMap` when
`caching.disableMaps` is on.
Some caveats:
- Obviously `getChannel` will do linear searching now, but this can be
skipped with guild hinting. `getChannel` now has a `guildIDHint`
parameter for getting that specific guild rather than searching all of
them. Which has some caveats:
- `editChannelPosition`'s option param has `guildIDHint`, it's channel's
corresponding function will use it.
- Same for `joinVoiceChannel` and `leaveVoiceChannel`, but
`leaveVoiceChannel` has it's hinting in a new parameter.
- `ThreadMember`'s construction to find the guild *will* do linear
searching, sad.
- Many of the shard events that use `getChannel` either now hint at the
guild or just gets the guild directly.
---------
Co-authored-by: TTtie <me@tttie.cz>
This commit switches Dysnomia over to ESLint flat config for
futureproofing and better maintainability. For the most part, the
codebase will pass the test suite, apart from a few exceptions
introduced by the stylistic plugin which I believe are reasonable to
include.
Additionally, JSDoc linting was added to maintain proper
alignment of various features.
this should introduce proper jsdoc inheritance and make it slightly more convertible
also unifies the cases when the docs would be written directly on the class field
* stage 0.5: move all props (almost) everywhere to their own blocks
* convert a couple more structures
* remove stray Guild import
* convert SharedStream, VoiceConnection
* convert Message structure
* feat(ThreadChannel): allow fetching more details about thread members
* feat(ThreadChannel): add singular thread member fetching
* remove redundant parameter
* member data from THREAD_MEMBERS_UPDATE is sent in the member field
* handle the guild not being cached accordingly
* consistently transform options in getThreadMember