Coder Social home page Coder Social logo

pb-tax's Introduction

npm version npm downloads creator

🇺🇸 En :

is an easy and simple package used efficiently to calculate discord's most advanced bot: ProBot

🇸🇦 Ar :

عبارة عن بكج سهلة وبسيطة تُستخدم بكفاءة لحساب بوت الديسكورد الأكثر تقدمًا: بروبوت

Installation

Node.js 16.9.0 or newer is required.

npm install pb-tax

Example :

import pbtax from "pb-tax"

const client = new Client({
    intents: ["GUILDS", "GUILD_MESSAGES"]
})

client.once('ready', () => {
    console.log(`${client.user.tag} is ready!`)
})

client.on('messageCreate', async (message) => {
    const prefix = `+`
    if(message.content.includes(`${prefix}tax`)) {
        const args = message.content.split(" ")
        const number = parseFloat(args[1])
        const tax = pbtax(number)
        const embed = new MessageEmbed()
        .setAuthor({name: `${message.author.tag}`, iconURL: `${message.author.avatarURL()}`})
        .setTimestamp()
        .setColor("BLURPLE")
        .addFields([
            {
                name: `All:`,
                value: `${tax.all}`,
                inline: true
            },
            {
                name: `Protax:`,
                value: `${tax.protax}`,
                inline: true
            },
            {
                name: `tax`,
                value: `${tax.tax}`,
                inline: true
            },
            {
                name: `wasit`,
                value: `${tax.wasit}`,
                inline: true
            },
        ])
        message.reply({embeds: [embed]})
    }
})

client.login(`TOKEN HERE!`)

pb-tax's People

Contributors

ahmdodev avatar s318367 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.