@m3rcena/weky
TypeScript icon, indicating that this package has built-in type declarations

6.5.0 • Public • Published

Weky


What is weky?

  • A fun npm package to play games within Discord with buttons!
  • looking for examples? click here: Examples

Features

  • 🧑 Beginner friendly
  • 🎉 Easy to use
  • ✨ Simple
  • 🔘 Discord Buttons
  • 🤖 Supports Discord.js V14
  • and much more!

Install the package 📥

npm install @m3rcena/weky

Example ✏️

Discord.js v14.0.0

Common-JS

const Discord = require('discord.js');
const client = new Discord.Client();
const { Calculator } = require('@m3rcena/weky/dist/index.cjs'); // temporary

client.on('ready', async () => {
	console.log(`Logged in as ${client.user.tag}`);
});

client.on('messageCreate', async (message) => {
	if (message.content === '!calculator') {
		await Calculator({
			message: message,
			embed: {
				title: 'Calculator | Weky Development',
				color: '#5865F2',
				footer: '©️ Weky Development',
				timestamp: true,
			},
			disabledQuery: 'Calculator is disabled!',
			invalidQuery: 'The provided equation is invalid!',
			othersMessage: 'Only <@{{author}}> can use the buttons!',
		});
	}
});

client.login('DISCORD_BOT_TOKEN');

Module:

import Discord from 'discord.js';
const client = new Discord.Client();
import { Calculator } from '@m3rcena/weky/';

client.on('ready', async () => {
	console.log(`Logged in as ${client.user.tag}`);
});

client.on('messageCreate', async (message) => {
	if (message.content === '!calculator') {
		await Calculator({
			message: message,
			embed: {
				title: 'Calculator | Weky Development',
				color: '#5865F2',
				footer: '©️ Weky Development',
				timestamp: true,
			},
			disabledQuery: 'Calculator is disabled!',
			invalidQuery: 'The provided equation is invalid!',
			othersMessage: 'Only <@{{author}}> can use the buttons!',
		});
	}
});

client.login('DISCORD_BOT_TOKEN');

Result 📤

Contributing 🤝

  • Contributions, issues and feature requests are welcome!
  • Feel free to check issues page.

Developers 👨‍💻

Discord 📰

Discord

Readme

Keywords

Package Sidebar

Install

npm i @m3rcena/weky

Weekly Downloads

42

Version

6.5.0

License

ISC

Unpacked Size

649 kB

Total Files

107

Last publish

Collaborators

  • m3rcena