-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbot.js
More file actions
28 lines (21 loc) · 688 Bytes
/
bot.js
File metadata and controls
28 lines (21 loc) · 688 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
//require("dotenv").config();
import "dotenv/config";
//const { Client, GatewayIntentBits, Partials } = require("discord.js");
import { Client, GatewayIntentBits, Partials } from "discord.js";
//const commandHandler = require("./commands");
import commandHandler from "./commands.js";
const client = new Client({
intents: [
GatewayIntentBits.Guilds,
GatewayIntentBits.GuildMessages,
GatewayIntentBits.DirectMessages,
GatewayIntentBits.MessageContent,
],
partials: [Partials.Channel],
});
console.log("Have you met Allen?");
client.login(process.env.BOT_TOKEN);
client.on("ready", () => {
console.log("💖");
});
client.on("messageCreate", commandHandler);