コンテンツにスキップ
Version: v1.3
目次

charts()

このコンテンツはまだ日本語訳がありません。

This function is used to generate a chart of the top users in a guild.

Parameter Type Required Description
message Message ✅ The message object.
options ChartOptions ❌ The options for the chart.

Image

  • new Error() - if invalid parameters are provided, or if there are not enough users to create a chart.
const { charts } = require("simply-xp");
charts(message, options)
.then(console.log) // Returns the chart object
.catch((err) => console.log(err)); // Returns the error

Options Type Required Default Description
position Number ❌ 5 Number of users needed to be in the chart
background Hex Code ❌ GREY Background color of the chart
type Chart Type ❌ bar Any one from these 'line' (or) 'bar' (or) 'radar' (or) 'doughnut' (or) 'polarArea