Botanique/src/utils/client.js

20 lines
407 B
JavaScript

import { Client, Intents } from 'discord.js';
import { readFileSync } from 'fs';
const { version } = JSON.parse(readFileSync('./package.json'));
// Création du client et de ses propriétés
export default async () => {
const client = new Client({
intents: [
Intents.FLAGS.GUILDS,
],
});
client.config = {
version: version,
token_discord: process.env.TOKEN_DISCORD,
};
return client;
};