discord.js Questions
4
I am trying to build a setup menu for my bot that the server owner can use to configure the bot. The menu is triggered when the owner types =setup. I want the bot to reply with several embed messag...
Evenings asked 17/10, 2019 at 20:44
3
I am using Discord.js library to create a discord bot. Whenever I am sending an embedded message to a text channel, its width keeps changing with different data.
const celestialObject = new Message...
Ingeringersoll asked 12/11, 2020 at 7:4
2
Solved
I want to get the ID of a discord slash command to make a simailar thing that MEE6 has: (discord.js)
Help:
/help [command]
This makes you able to click on the slash command this is displayed insi...
Viand asked 7/10, 2022 at 7:42
4
I was working with discord.js last night and I ran a few commands in the terminal. The last command I wrote caused the name of the file at the top of the screen to be crossed out and turn red and I...
Palocz asked 23/1, 2022 at 10:5
4
Solved
I try to use fs on a discordjs bot (v13) but I have a strange error.
I have literally 3 lines between the moment when I can console.log my fs object and the error :
// Get FS
const fs = require('f...
Gravimetric asked 1/5, 2022 at 15:24
2
Solved
I'm getting this warning in the terminal when running my bot code:
(node:6220) DeprecationWarning: Passing strings for MessageEmbed#setFooter is deprecated. Pass a sole object instead.(Use node --t...
Fink asked 6/1, 2022 at 3:59
10
Solved
I am trying to make a discord bot, but I can't quite understand Discord.js.
My code looks like this:
client.on('message', function(message) {
if (message.content === 'ping') {
client.message.send...
Duodiode asked 15/7, 2017 at 16:50
6
Solved
I have this code:
var datos = ["dato1","dato2","dato3"]
console.log ("》" + message.author.username + " introdujo el comando: " + message.content + " en " + message.guild.name);
let embed = new d...
Browse asked 5/7, 2018 at 21:9
2
Error: Cannot find module 'node:fs'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
at Function.Module._load (internal/modules/cjs/loader.js:562:25)
at Module.requir...
Expansion asked 19/5, 2022 at 17:55
3
Solved
I am implementing a command to mute users. For example, the following command would mute the user @anon for 5 seconds:
!mute @anon 5
My program listens for the message event, mutes the user and ...
Decarbonize asked 20/5, 2020 at 10:3
2
Solved
I am trying to make an embed with only 2 columns. Whenever I delete the inline value it drops test3 field like I want. Then I keep inline: true on test4 field and it drops to another row. I tried m...
Missive asked 5/3, 2021 at 1:5
5
Solved
I'm making a discord bot in TypeScript using discord.js. When I tried to compile code this morning I got this error:
C:\SECRET\Kostegator\dist\Util\getMeme.js:17
const node_fetch_1 = __importDefaul...
Alonaalone asked 23/1, 2022 at 7:42
7
I saw that NotSoBot has his status as online on mobile, is there a way that I can do that in discord.js?
Honesty asked 26/2, 2020 at 10:18
6
Solved
Here is my configuration file.
import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm';
@Entity({ name: 'guild_configurations' })
export class GuildConfiguration {
@PrimaryGeneratedColum...
Elainaelaine asked 23/3, 2022 at 9:58
4
I've encountered a problem while setting up mongoose.
Here is my code:
const { SlashCommandBuilder } = require('@discordjs/builders');
const testSchema = require(`../../Schemas.js/test`);
module.e...
Langue asked 6/3, 2023 at 9:52
4
I need a Regex to match all unicode emojis.
I need this to check if a discord message has a Unicode Emoji in it.
// Here is a example of matching one Unicode Emoji
message.content.match(/😊/g...
Tokharian asked 24/10, 2020 at 3:17
3
How I can fill the empty array with attachments url, so I can send them all of them in one message?
Because when I send use url varaible, same message will be sent several times depending on attach...
Overview asked 26/12, 2021 at 21:33
16
I'm trying to make a discord bot with the command prefix "*" but when I try to get the bot online/run it, it gives me this error:
node:internal/modules/cjs/loader:936
node:internal/modul...
Vengeful asked 7/8, 2021 at 13:50
6
According to new update youu can set your own custom status without playing or listening this is't added in documentation yet what can I do here. There is no option to set custom activity in the di...
Septuple asked 26/10, 2019 at 5:42
4
Solved
node:v16.11.0
"discord.js": "^13.2.0"
I am setting up an example Discord.js bot.
In this guide, I am to the point of adding this line:
client.commands = new Collection();
Typesc...
Redhanded asked 8/10, 2021 at 18:54
2
I'm currently having issues connecting to my database with mongoose. The status is degraded and I can't browse through my collections. I have no idea how this happened nor how to fix it. Any help i...
Arlyn asked 25/2, 2022 at 14:49
8
Solved
Ok, so I searched for a while, but I couldn't find any information on how to delete all messages in a discord channel. And by all messages I mean every single message ever written in that channel. ...
Northwester asked 12/1, 2018 at 14:53
4
Here is my code that is trying to access the user's avatar:
Client.on("guildMemberAdd", newMember => {
console.log("Welcomed member avatar: " + newMember.user.avatar);
console.log("Welcomed m...
Nonmaterial asked 6/2, 2019 at 15:5
3
Solved
I was requiring some data from a .json file but I am getting this error:
Error: ENOENT: no such file or directory, open '../Jsons/eshop.json'
at Object.openSync (node:fs:585:3)
at Object.readFile...
Bugger asked 7/4, 2022 at 6:57
3
Solved
I'm not sure what's wrong. I deleted my code and downloaded it then uploaded it again and now I get this error.
Code: https://replit.com/@hi12167pies/webcord#index.js (Click code for code and outpu...
Sidonie asked 7/8, 2021 at 11:38
1 Next >
© 2022 - 2024 — McMap. All rights reserved.