Skip to content
pubscout

angel3_websocket

10.0.1, released 3 weeks ago by dukefirehawk.com

WebSockets support and event broadcasting for the Angel3 framework.

WASM-ready
$ flutter pub add angel3_websocket
Source repository

What it does

Provides WebSocket server integration and client libraries for Angel3. It automatically broadcasts events from hooked services, adds WebSocket support to controllers, and allows reconnection handling on both browser and CLI clients.

AI-written summary of version 10.0.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You are building an Angel3 backend and need real-time WebSocket communication.
  • You want automatic broadcasting of service events to connected clients.
  • You need CLI or browser WebSocket clients compatible with Angel3 services.

Skip it when

  • You are using a backend framework other than Angel3.
  • You only need raw WebSockets without framework bindings or hooked services.

Strengths

  • Automatic broadcasting of service events
  • Built-in JWT authentication over WebSockets
  • Includes both browser and CLI client implementations with auto-reconnect

Weaknesses

  • Tightly coupled to the Angel3 framework ecosystem
  • Does not support WebSockets over HTTP/2 (refuses with 501)

Setup

Kind
Pure Dart
Effort
Low
Code generation
Yes (build_runner)
Direct dependencies
12

Configure the server plugin with app.configure(ws.configureServer) and map routes with ws.handleRequest.

import "package:angel3_framework/angel3_framework.dart";
import "package:angel3_websocket/server.dart";

void main() async {
  var app = Angel();
  var ws = AngelWebSocket(app);
  await app.configure(ws.configureServer);
  app.all('/ws', ws.handleRequest);
}

Alternatives

Packages that do the same job and could replace angel3_websocket.

Works with

Packages commonly used together with angel3_websocket: ones it builds on, ones built on it, and its own family.