[PR #112] [MERGED] BREAKING: remove polyfilles, CJS build, and update dev dependencies #114

Closed
opened 2026-02-16 12:27:03 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/stoatchat/javascript-client-sdk/pull/112
Author: @williamhorning
Created: 3/14/2025
Status: Merged
Merged: 3/23/2025
Merged by: @insertish

Base: mainHead: break-node-prior-to-22


📝 Commits (6)

  • 5397269 BREAKING CHANGE: remove isomorphic-ws, long, eventemitter3
  • 00dff72 BREAKING CHANGE: remove CJS build
  • 623f9c1 chore: update prettier and eslint
  • 6e8330f chore: fix lint and formatting errors
  • fed74bc chore: update solid primatives
  • 897df03 fix: this logic was wrong, match original pr

📊 Changes

39 files changed (+1482 additions, -2346 deletions)

View changed files

.eslintrc.json (+0 -49)
eslint.config.js (+23 -0)
package-esm.json (+0 -3)
📝 package.json (+19 -30)
📝 pnpm-lock.yaml (+1165 -1960)
📝 src/Client.ts (+54 -57)
📝 src/classes/Channel.ts (+47 -44)
📝 src/classes/ChannelWebhook.ts (+5 -4)
📝 src/classes/Emoji.ts (+1 -1)
📝 src/classes/File.ts (+1 -1)
📝 src/classes/MFA.ts (+2 -2)
📝 src/classes/Message.ts (+14 -12)
📝 src/classes/MessageEmbed.ts (+5 -5)
📝 src/classes/PublicInvite.ts (+1 -1)
📝 src/classes/Server.ts (+44 -44)
📝 src/classes/ServerBan.ts (+1 -1)
📝 src/classes/ServerMember.ts (+2 -2)
📝 src/classes/SystemMessage.ts (+6 -6)
📝 src/classes/User.ts (+11 -11)
📝 src/collections/AccountCollection.ts (+1 -1)

...and 19 more files

📄 Description

  • BREAKING: remove isomorphic-ws and ws. node 22+ (current LTS) support WebSocket out of the box so there's no need to keep shipping these polyfills
  • BREAKING: remove CJS builds. node 20+ support requiring synchronous ESM graphs, so there's no reason to ship a CJS build anymore
  • chore: update prettier and eslint to their latest versions
  • chore: fix lint and formatting errors (mostly trailing commas)

this, along with https://github.com/insertish/oapi/pull/3/ should reduce what revolt.js depends on without breaking any usecases

this does break support for node <22, but we shouldn't support anything less than the latest LTS

dependency graph


  • I understand and have followed the contribution guide
  • I have tested my changes locally and they are working as intended

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/stoatchat/javascript-client-sdk/pull/112 **Author:** [@williamhorning](https://github.com/williamhorning) **Created:** 3/14/2025 **Status:** ✅ Merged **Merged:** 3/23/2025 **Merged by:** [@insertish](https://github.com/insertish) **Base:** `main` ← **Head:** `break-node-prior-to-22` --- ### 📝 Commits (6) - [`5397269`](https://github.com/stoatchat/javascript-client-sdk/commit/5397269ae646b21f9761e14f85de16a086777808) BREAKING CHANGE: remove isomorphic-ws, long, eventemitter3 - [`00dff72`](https://github.com/stoatchat/javascript-client-sdk/commit/00dff72b7853e0ad6638fca0fd81c0690dc37cd9) BREAKING CHANGE: remove CJS build - [`623f9c1`](https://github.com/stoatchat/javascript-client-sdk/commit/623f9c1bd641907ff1c7eb18242d9eac3e25ee88) chore: update prettier and eslint - [`6e8330f`](https://github.com/stoatchat/javascript-client-sdk/commit/6e8330f95c7a2f50dd81c81d7606d4ab4f608d2d) chore: fix lint and formatting errors - [`fed74bc`](https://github.com/stoatchat/javascript-client-sdk/commit/fed74bc9f33725ccf764e1355c39d85e09582f24) chore: update solid primatives - [`897df03`](https://github.com/stoatchat/javascript-client-sdk/commit/897df0392efddd198e61d79d9c08cfb32da00a39) fix: this logic was wrong, match original pr ### 📊 Changes **39 files changed** (+1482 additions, -2346 deletions) <details> <summary>View changed files</summary> ➖ `.eslintrc.json` (+0 -49) ➕ `eslint.config.js` (+23 -0) ➖ `package-esm.json` (+0 -3) 📝 `package.json` (+19 -30) 📝 `pnpm-lock.yaml` (+1165 -1960) 📝 `src/Client.ts` (+54 -57) 📝 `src/classes/Channel.ts` (+47 -44) 📝 `src/classes/ChannelWebhook.ts` (+5 -4) 📝 `src/classes/Emoji.ts` (+1 -1) 📝 `src/classes/File.ts` (+1 -1) 📝 `src/classes/MFA.ts` (+2 -2) 📝 `src/classes/Message.ts` (+14 -12) 📝 `src/classes/MessageEmbed.ts` (+5 -5) 📝 `src/classes/PublicInvite.ts` (+1 -1) 📝 `src/classes/Server.ts` (+44 -44) 📝 `src/classes/ServerBan.ts` (+1 -1) 📝 `src/classes/ServerMember.ts` (+2 -2) 📝 `src/classes/SystemMessage.ts` (+6 -6) 📝 `src/classes/User.ts` (+11 -11) 📝 `src/collections/AccountCollection.ts` (+1 -1) _...and 19 more files_ </details> ### 📄 Description - BREAKING: remove `isomorphic-ws` and `ws`. node 22+ (current LTS) support WebSocket out of the box so there's no need to keep shipping these polyfills - BREAKING: remove CJS builds. node 20+ support requiring synchronous ESM graphs, so there's no reason to ship a CJS build anymore - chore: update `prettier` and `eslint` to their latest versions - chore: fix lint and formatting errors (mostly trailing commas) this, along with https://github.com/insertish/oapi/pull/3/ should reduce what revolt.js depends on without breaking any usecases this does break support for node <22, but we shouldn't support anything less than the latest LTS ![dependency graph](https://github.com/user-attachments/assets/6f0bc09f-53a8-40da-bd42-48ce959cbd71) --- - [X] I understand and have followed the [contribution guide](https://github.com/revoltchat/.github/blob/master/.github/CONTRIBUTING.md) - [X] I have tested my changes locally and they are working as intended --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 12:27:03 -05:00
yindo closed this issue 2026-02-16 12:27:03 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: stoatchat/javascript-client-sdk#114