New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

discord-typings

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

discord-typings - npm Package Compare versions

Comparing version 10.0.3 to 10.1.0

15

index.js
// XD. What are you looking here for???
module.exports = {};
/**
* @type {{ default: never; }}
*/
// @ts-ignore
const fakeExports = {};
Object.defineProperty(fakeExports, "default", {
/**
* @returns {never}
*/
get: () => {
throw new Error("Do not use this module in code as it only exports type defs");
}
});
module.exports = fakeExports;

@@ -36,2 +36,3 @@ import { Snowflake } from "../Reference";

options?: Array<import("./ApplicationCommands").ApplicationCommandInteractionDataOption>;
guild_id?: Snowflake;
custom_id?: string;

@@ -38,0 +39,0 @@ component_type?: import("./MessageComponents").ComponentType;

2

package.json
{
"name": "discord-typings",
"version": "10.0.3",
"version": "10.1.0",
"description": "Typings for data returned by Discord (unofficial)",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -10,3 +10,3 @@ import { Snowflake } from "../Reference";

integrations: Array<import("./Guild").Integration>;
threads: Array<import("./Channel").NewsThread | import("./Channel").PublicThread | import("./Channel").PrivateThread>;
threads: Array<import("./Channel").ThreadChannel>;
users: Array<import("./User").User>;

@@ -13,0 +13,0 @@ webhooks: Array<import("./Webhook").Webhook>;

@@ -18,3 +18,3 @@ import { Snowflake } from "../Reference";

*/
export interface GuildChannel extends ChannelBase {
export interface GuildBasedChannel extends ChannelBase {
guild_id: Snowflake;

@@ -33,3 +33,3 @@ position: number;

*/
export interface TextChannel extends TextBasedChannel, GuildChannel {
export interface TextChannel extends TextBasedChannel, GuildBasedChannel {
type: 0;

@@ -52,3 +52,3 @@ topic: string | null;

*/
export interface GuildVoiceBasedChannel extends GuildChannel {
export interface GuildVoiceBasedChannel extends GuildBasedChannel {
bitrate: number;

@@ -70,3 +70,3 @@ user_limit: number;

*/
export interface CategoryChannel extends GuildChannel {
export interface CategoryChannel extends GuildBasedChannel {
type: 4;

@@ -78,3 +78,3 @@ }

*/
export interface NewsChannel extends TextBasedChannel, GuildChannel {
export interface NewsChannel extends TextBasedChannel, GuildBasedChannel {
type: 5;

@@ -87,3 +87,3 @@ topic: string | null;

*/
export interface ThreadBasedChannel extends TextBasedChannel, GuildChannel {
export interface ThreadBasedChannel extends TextBasedChannel, GuildBasedChannel {
message_count: number;

@@ -94,2 +94,3 @@ member_count: number;

default_auto_archive_duration: number;
flags?: number;
}

@@ -130,12 +131,14 @@

*/
export interface DirectoryChannel extends GuildChannel {
export interface DirectoryChannel extends GuildBasedChannel {
type: 14;
}
export interface ForumChannel extends GuildBasedChannel {
type: 15;
}
/**
* https://discord.com/developers/docs/resources/channel#channel-object-channel-structure
*/
export interface UnknownChannel extends ChannelBase {
type: ChannelType;
}
export type Channel = TextChannel | DMChannel | VoiceChannel | CategoryChannel | NewsChannel | NewsThread | PublicThread | PrivateThread | StageChannel | DirectoryChannel | ForumChannel;

@@ -145,8 +148,10 @@ /**

*/
export type Channel = TextChannel | DMChannel | VoiceChannel | CategoryChannel | NewsChannel | NewsThread | PublicThread | PrivateThread | StageChannel | DirectoryChannel | UnknownChannel;
export type GuildChannel = Exclude<Channel, DMChannel | NewsThread | PublicThread | PrivateThread>;
export type ThreadChannel = NewsThread | PublicThread | PrivateThread;
/**
* https://discord.com/developers/docs/resources/channel#channel-object-channel-types
*/
export type ChannelType = 0 | 1 | 2 | 4 | 5 | 10 | 11 | 12 | 13 | 14;
export type ChannelType = 0 | 1 | 2 | 4 | 5 | 10 | 11 | 12 | 13 | 14 | 15;

@@ -153,0 +158,0 @@ /**

@@ -29,2 +29,3 @@ import { Snowflake } from "../Reference";

system_channel_id: Snowflake | null;
system_channel_flags: number;
rules_channel_id: Snowflake | null;

@@ -37,4 +38,4 @@ joined_at?: string;

members?: Array<Member>;
channels?: Array<import("./Channel").TextChannel | import("./Channel").VoiceChannel | import("./Channel").CategoryChannel | import("./Channel").NewsChannel | import("./Channel").StageChannel | import("./Channel").DirectoryChannel>;
threads?: Array<import("./Channel").NewsThread | import("./Channel").PublicThread | import("./Channel").PrivateThread>;
channels?: Array<import("./Channel").GuildChannel>;
threads?: Array<import("./Channel").ThreadChannel>;
presences?: Array<import("../Topics/Gateway").PresenceUpdate>;

@@ -41,0 +42,0 @@ max_presences?: number | null;

@@ -7,3 +7,3 @@ /**

guild?: import("./Guild").Guild;
channel: import("./Channel").TextChannel | import("./Channel").VoiceChannel | import("./Channel").CategoryChannel | import("./Channel").NewsChannel | import("./Channel").StageChannel | import("./Channel").DirectoryChannel;
channel: import("./Channel").GuildChannel;
inviter?: import("./User").User;

@@ -10,0 +10,0 @@ target_type?: InviteTarget;

@@ -164,3 +164,3 @@ import { Snowflake } from "../Reference";

channel_ids?: Array<Snowflake>;
threads: Array<import("../Resources/Channel").NewsThread | import("../Resources/Channel").PublicThread | import("../Resources/Channel").PrivateThread>;
threads: Array<import("../Resources/Channel").ThreadChannel>;
members: Array<import("../Resources/Channel").ThreadMember>;

@@ -167,0 +167,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc