Releases: pubnub/javascript
Releases · pubnub/javascript
v9.1.0
March 13 2025
Added
SubscriptionSetwill re-add listener every time whenSubscriptionorSubscriptionSetadded to it - this will let receive updates from newly added subscribe capable objects.
Fixed
- Fix issue because of errors returned by
fetchtaken fromiframe(to protect against monkey-patching by APM packages) was't handled as Error.
Modified
- Use access token (auth key) content instead of base64 encoded token to identify PubNub clients, which can be used for requests aggregation.
v9.0.0
March 10 2025
Added
- BREAKING CHANGES:
SubscriptionSetwill subscribe / unsubscribe added / removedSubscriptionorSubscriptionSetobjects if the set itself already subscribed.
Fixed
- Fix issue because of which throttle didn't consider difference in client settings (throttled only by user ID and subscribe key, which is not enough).
- With the fix, smart heartbeat as feature has been added to the SDK, and it is disabled by default.
v8.10.0
March 06 2025
Added
- Add
useSmartHeartbeatconfiguration option which allows ignoring implicit heartbeat (with successful subscribe response) and keep sendingheartbeatcalls with fixed intervals. subscriptionWorkerOfflineClientsCheckIntervalconfiguration option can be used to configure the interval at which “offline” PubNub clients (when tab closed) detection will be done.subscriptionWorkerUnsubscribeOfflineClientsconfiguration option can be used to force unsubscribe (presence leave) for “offline” PubNub clients (when tab closed).
v8.9.1
February 26 2025
Fixed
- Fix issue because of which code doesn't handle edge case when
fetchreject with empty object and notError.
Modified
- Remove
-pnpreschannels and groups from presenceleaveandheartbeatrequests.
v8.9.0
February 18 2025
Added
- Emit 'PNDisconnectedUnexpectedlyCategory' in cases when client receives bad request or unexpected / malformed service response.
Modified
- Move error / malformed response handling into
AbstractRequestto simplify actual endpoint classes.
v8.8.1
February 10 2025
Fixed
- Fix issue because of which APM fix worked only when the client has been configured with
logVerbosity: true.
v8.8.0
February 05 2025
Added
- For the browser version of PubNub SDK, add the ability to switch between
fetchandxhrAPIs (transportconfiguration option).
Fixed
- Fix issue because of which, in Event Engine mode, wrong timeout values have been set for requests which create long-poll request.
Modified
- Refactor
timeoutimplementation forfetchtransport to properly cancel request when the timeout timer will fire.
v8.7.1
January 31 2025
Fixed
- Fix long-poll request cancellation caused by APM packages monkey patching 'fetch' and try to use 'native' implementation instead of patched.
v8.7.0
January 30 2025
Added
- Pass heartbeat request through
SharedWorker(if used) to optimize the number of requests for clients opened in few tabs and subscribed on same channels / groups list.
Modified
- Don't send
heartbeatrequest to unsubscribe.
v8.6.0
January 21 2025
Added
- A new optional parameter
ifMatchesEtagis added tosetUUIDMetadataandsetChannelMetadata. When provided, the server compares the argument value with the ETag on the server and if they don't match a HTTP 412 error is returned.