
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
// Using npm
npm install poru
// Using yarn
yarn add poru
To use you need a configured Lavalink instance.
Poru Music Example bot as guide for beginning.
// main file
// Require both libraries
const { Client } = require("discord.js");
const { Poru } = require("poru");
// Initiate both main classes
const client = new Client();
// Define some options for the node
const nodes = [
{
host: "localhost",
password: "youshallnotpass",
port: 2333,
secure:false
}
];
// Assign Manager to the client variable
client.poru = new Poru(client,nodes);
// Emitted whenever a node connects
client.poru.on("nodeConnect", node => {
console.log(`Node "${node.name}" connected.`)
})
// Emitted whenever a node encountered an error
client.poru.on("nodeError", (node, error) => {
console.log(`Node "${node.name}" encountered an error`)
})
// Listen for when the client becomes ready
client.once("ready", () => {
client.poru.init(client;
console.log(`Logged in as ${client.user.tag}`);
});
// this event used to make connections upto date with lavalink
client.on("raw",async d => await client.poru.packetUpdate(d));
// Finally login at the END of your code
client.login("your bot token here");
// creating player
const player = await client.poru.createConnection({
guild: message.guild.id,
voiceChannel: message.member.voice.channel.id,
textChannel: message.channel,
selfDeaf: true,
selfMute: false,
})
// Getting tracks
const resolve = await client.poru.resolve('Ignite',"yt");
Feel free to join our discord server, Give us suggestions and advice about errors and new features. with ❤️ by Paras .
FAQs
A stable and powerful lavalink client around node.js
The npm package poru receives a total of 121 weekly downloads. As such, poru popularity was classified as not popular.
We found that poru demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.