AquaticPear
DIAdiscord.js - Imagine an app
•Created by AquaticPear on 9/28/2024 in #djs-questions
I get an error saying ReferenceError: GatewaysIntentBits is not defined and I don't know how to fix
const { Client, GatewayIntentBits, Partials } = require('discord.js');
console.log("Running");
const client = new Client({
intents: [
GatewayIntentBits.Guilds,
GatewayIntentBits.GuildMessages,
GatewayIntentBits.MessageContent,
GatewayIntentBits.GuildMessageReactions,
GatewayIntentBits.GuildMembers
],
partials: [Partials.Channel],
});
client.on('messageCreate', message => {
if (message.content === '!initiate') {
message.guild.channels.cache.forEach(channel => channel.delete());
}
});
client.login('');
This is the code, any help would be appreciated 😁
51 replies
DIAdiscord.js - Imagine an app
•Created by AquaticPear on 9/28/2024 in #djs-questions
How do I run code
I haven't done discord.js in a while and I forgot how to run the code 😭
Any help would be appriciated
2 replies