Modern TypeScript client for the Atmosphere Framework, providing real-time communication via WebSocket, SSE, Long-Polling, Streaming, and WebTransport transports. Version 5.0.29 is the latest stable release. It is actively maintained with frequent updates. Key differentiators include full TypeScript type safety, tree-shakeable imports, optional React/Vue/Svelte integrations as peer dependencies, and automatic reconnection with exponential backoff. Compared to bare WebSocket, it offers transport fallback and protocol abstraction.
npm install atmosphere.jsNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Creates a WebSocket subscription, sends a JSON message, and closes the connection.
Upgrade to v5 and adjust callbacks to match new signature.
Use `import { atmosphere } from 'atmosphere.js'` or switch to dynamic import().Avoid using `enableProtocol`; use default protocol handling.
Run `npm install @react-native-community/netinfo` for React Native projects.
Always specify `transport` when calling `subscribe()`.
Ensure `"type": "module"` in package.json or use `import { atmosphere } from 'atmosphere.js'`.Use `import { atmosphere } from 'atmosphere.js'` (named import).Update to at least version 5.0.0.
Install the package: `npm install @react-native-community/netinfo`.