Skip to main content

registerPlugins()

Register plugins to extend simply-xp functionality, making this even more powerful.

danger

PLUGINS HAVE FULL CONTROL OVER YOUR PROCESS, ONLY USE WHAT YOU TRUST.

If you're unsure which plugins to use, check out our Plugin Registry.

Parameters​

ParameterTypeRequiredDescription
pluginsPlugin[]βœ…Array of plugins.

Return value​

  • void - Nothing is returned by this function.

Throws​

  • XpFatal - If one or more plugins are invalid, or an array is not provided.

Example​

const {registerPlugins} = require("simply-xp");
const rateLimits = require("@simply-xp/rate-limits");

registerPlugins([rateLimits])
.catch(console.error); // Returns the error