Repository navigation
Open
4 / 44 of 4 issues completedLabels
enhancementNew feature or request
Description
Problem
Track basic in-memory ws support within the v2 direction. This issue groups the runtime, public-type, and package work. Each implementation PR should close its own sub-issue.
Proposed API
import WebSocket, { WebSocketServer } from 'smocket/ws';
const server = new WebSocketServer({ port: 3000 });
server.on('connection', (socket) => {
socket.on('message', (data) => socket.send(data.toString()));
});
const client = new WebSocket('ws://localhost:3000');
client.onopen = () => client.send('hello');
client.onmessage = () => client.close();This is the target package usage. The internal runtime in #580 does not provide the public entry point; package binding belongs to #562.
Socket.IO behavior
Keep existing Socket.IO behavior unchanged. Follow real ws for the supported application APIs and observable behavior, within ADR 0044 and the CommonJS export decision in ADR 0045.
Scope check
- This is not reconnection, transport fallback, heartbeat, Redis multi-server, or binary encoding
Tasks
- Define usage and public types in feat: define ws usage and public types #555.
- Prepare independent package consumer checks in test: prepare ws package consumer checks #567.
- Implement and compare the internal basic runtime in feat: implement the internal ws runtime #580.
- Connect the actual entry points and verify generated declarations and packed consumers in feat: add ws entry points and package consumer checks #562.
Client tracking and multi-client application examples remain in #539. Byte inputs, send callbacks, and detailed failure/concurrent-close behavior remain in #540. Shared-core extraction in #541 follows the ws work and does not block it.
Sub-issues
Collapse Sub-issuesSub-issues
Loading 4 sub-issues
Metadata
Metadata
Assignees
Labels
enhancementNew feature or request
Type
Projects
- StatusShow more project fieldsBacklog
Activity
[-]feat: add ws environment and basic browser messaging[/-][+]feat: add basic ws messaging[/+]