Üye
JavaScript:
const { Client } = require('discord.js');
const client = new Client();
client prefix = '!';
client.on('message', (message) => {
if (!message.content.startsWtih(prefix) || message.author.bot) return;
const args = message.content.slice(prefix.length).split(/ +/);
const komut = args.shift().toLowerCase();
if (komut === 'tarih') {
message.react('✔️');
message.channel.send('Tarih hesaplanıyor...').then(async message => {
message.delete();
const tarih = new Date();
const ay = tarih.getMonth() + 1;
message.channel.send('\n' + 'Tarih: ' + tarih.getDate() + ay + tarih.getFullYear() + '\n' + 'Saat: ' + tarih.getHours() + .tarihgetMinutes() + .tarihgetSecons() + .tarihgetMilliseconds())
});
}
});
//!tarih yazınca tarih ve saati gösterecektir.