1.3.0 • Published 3 years ago

discordjs-functions-shortcuts v1.3.0

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

About

discordjs-functions-shortcuts is a shortcuts thingy I made for myself. So.... uh, yea.


Installation

With node.js installed simply run:

# Run this to install discordjs-functions-shortcuts locally to your repository. 
$ npm install discordjs-functions-shortcuts

# Alternatively, if you are using yarn:
$ yarn add discordjs-functions-shortcuts

# To use discordjs-functions-shortcuts anywhere, run this code to install the package globally:
$ npm install discordjs-functions-shortcuts -g

generatePort Function

1) Install discordjs-functions-shortcuts.

2) Write your code.

    // Require the necessary discord.js classes
const { Client, Intents } = require('discord.js');
const { token } = require('./config.json');

// Create a new client instance
const client = new Client({ intents: [Intents.FLAGS.GUILDS] });

// Require discordjs-functions-shortcuts
const generatePort = require('discordjs-functions-shortcuts');

generatePort;

// When the client is ready, run this code (only once)
client.once('ready', () => {
	console.log('Ready!');
});

// Login to Discord with your client's token
client.login(token);

createServer Function

    // Require the necessary discord.js classes
const { Client, Intents } = require('discord.js');
const { token } = require('./config.json');

// Create a new client instance
const client = new Client({ intents: [Intents.FLAGS.GUILDS] });

// Require discordjs-functions-shortcuts
const createServer = require('discordjs-functions-shortcuts');

createServer('example.html');

// When the client is ready, run this code (only once)
client.once('ready', () => {
	console.log('Ready!');
});

// Login to Discord with your client's token
client.login(token);

You are now using discordjs-functions-shortcuts!


Credits


License

MIT

1.3.0

3 years ago

1.2.0

3 years ago

1.1.4

3 years ago

1.1.3

3 years ago

1.1.2

3 years ago

1.1.1

3 years ago

1.1.0

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.0

3 years ago