# Vendored From

- Package: `ws`
- Upstream version: `8.21.1`
- Upstream tag: `8.21.1`
- Upstream repository: `https://github.com/websockets/ws`
- Upstream license: `MIT`
- Date vendored: `2026-07-21`

## Purpose

This directory contains the vendored WebSocket runtime used by
`@causal-order/transport`.

The intent is to keep the publish boundary stable and self-contained while
exposing only the narrower transport wrapper used by this package.

## Local Packaging Notes

- `package.json` in this directory is a local packaging shim used so the
  vendored upstream `lib/*.js` files continue to load correctly inside this
  ESM package.
- `src/internal/ws-runtime.ts` is the supported internal wrapper boundary that
  imports this vendored runtime.

## Local Modifications

- No functional source changes to the upstream `ws` runtime were introduced at
  vendoring time.
- The local `package.json` file in this directory was added for module-loading
  compatibility inside `@causal-order/transport`.
- After vendoring, the optional runtime probing for `bufferutil` and
  `utf-8-validate` was removed so this copy always uses the built-in Node
  `buffer.isUtf8` path when available and otherwise falls back to the local
  JavaScript implementation.

## Update Checklist

- Record the new upstream version here.
- Keep `THIRD_PARTY_NOTICES.md` in sync.
- Preserve the upstream `LICENSE`.
- Note any local patches made after the initial vendoring step.
