Closed adolfo-pd closed 6 days ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
The changes in this pull request modify the ServerAsyncResponseManager
class within the async.ts
file. The constructor now ensures type safety by casting WS
to adapters.WebSocket
. Additionally, two global functions, addEventListener
and removeEventListener
, are introduced with empty implementations. The getOpts
method remains unchanged but continues to validate OAuth token structures and retrieve project IDs, returning relevant WebSocket URL and subscription parameters. Overall, the focus is on enhancing type safety while preserving existing functionality.
File Path | Change Summary |
---|---|
packages/sdk/src/server/async.ts | Updated ServerAsyncResponseManager constructor for type safety with adapters.WebSocket . Added empty implementations for addEventListener and removeEventListener . Introduced type ServerAsyncResponseManagerOpts and class ServerAsyncResponseManager . |
ServerAsyncResponseManager
class in async.ts
, including the addition of global functions and improvements to the getOpts
method, which are closely related to the modifications made in the main PR.In the server's heart, a change so bright,
WebSocket's cast, now just feels right.
With listeners added, though silent they stay,
Type safety blooms in a code ballet.
Hops of joy for the code we mend,
In the world of async, our changes blend! 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
WHY
Summary by CodeRabbit
New Features
Bug Fixes