Skip to content

docs: assign Socket types by package - #241

Merged
electrohyun merged 1 commit into
mainfrom
docs/socket-export-decision
Aug 12, 2026
Merged

electrohyun merged 1 commit into
mainfrom
docs/socket-export-decision

Conversation

@electrohyun

@electrohyun electrohyun commented Aug 12, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Record ADR 0022 from the Socket.IO 4.7.5 and 4.8.3 package surfaces: socket.io and socket.io-client each export their own generic Socket, with four server generic positions and two direction-reversed client positions. External node16 and bundler fixtures verified the valid calls and rejected the wrong event direction on both versions.
  • Assign the smocket root Socket name to ServerSocketContract, matching the root's existing Server ownership and allowing server code to replace only the package name in import { Server, type Socket } from 'socket.io'.
  • Assign the client Socket name to a separate smocket-client package so client code can likewise replace only socket.io-client with smocket-client. Reject client/server subpaths because they introduce a Smocket-specific import convention instead of preserving Socket.IO's package-level split.
  • Require feat: define client-compatible package entry points #235 to define smocket-client as a thin facade over the shared implementation, including synchronized versions and publication without duplicated connection state, while leaving executable ESM default and CommonJS callable behavior to that package-boundary decision.
  • Leave runtime Socket constructors unpromised because Socket.IO's public constructors and Smocket's internal constructors have different inputs, then classify the future type aliases through ADR 0019 and update the decision index and v1 roadmap dependency.

Related issue

Closes #178

Checklist

  • Tests added or updated (not applicable: documentation-only decision)
  • Behavior verified against real socket.io

@github-actions github-actions Bot added documentation Improvements or additions to documentation 📏 m Pull request changes 50–199 lines labels Aug 12, 2026
@coderabbitai

coderabbitai Bot commented Aug 12, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

@electrohyun, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 53 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 027e282e-a32d-4d36-a33f-b5204b56f2cd

📥 Commits

Reviewing files that changed from the base of the PR and between 0c757ba and 5091101.

📒 Files selected for processing (3)
  • docs/decisions/0022-root-socket-names-server-socket.md
  • docs/decisions/README.md
  • docs/roadmap.md

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@electrohyun
electrohyun force-pushed the docs/socket-export-decision branch from 8f94b8f to ae3741b Compare August 12, 2026 04:55
@electrohyun
electrohyun force-pushed the docs/socket-export-decision branch from ae3741b to 5091101 Compare August 12, 2026 04:57
@electrohyun electrohyun changed the title docs: record directional Socket type ownership docs: assign Socket types by package Aug 12, 2026
@electrohyun
electrohyun merged commit 63878af into main Aug 12, 2026
15 checks passed
@electrohyun
electrohyun deleted the docs/socket-export-decision branch August 12, 2026 05:00
@electrohyun electrohyun self-assigned this Aug 12, 2026
@github-project-automation github-project-automation Bot moved this to Backlog in smocket Aug 27, 2026
@github-project-automation github-project-automation Bot moved this from Backlog to Done in smocket Aug 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation 📏 m Pull request changes 50–199 lines

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

feat: decide what smocket exports as Socket

1 participant