Using discordjs as a standlone file without nodejs
When trying to use https://www.jsdelivr.com/package/npm/discord.js
Action.js:3 Uncaught ReferenceError: require is not defined
at Action.js:3:18
jsDelivr
discord.js CDN by jsDelivr - A CDN for npm and GitHub
A free, fast, and reliable CDN for discord.js. A powerful library for interacting with the Discord API
6 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
Do you have any suggestion as to which library I can use. I can alway use nodejs in the background but I am trying to figure out a way to make it run standlone in a html page instead of a nodejs script
Unknown User•5mo ago
Message Not Public
Sign In & Join Server To View
Thank you so much 🙂
discord.js (the whole lib) is not web compatible
You're probably better off using only specific modules
Embedding it in HTML would only expose your token