Files
hyperframes/packages/studio/vite.request-signal.ts
Miguel Ángel 67dbcf7bdb feat(studio): preview timeline track insertion (#4907)
* feat(studio): preview new tracks at drop boundaries

* fix(studio): preserve group ownership across overlapping moves

* refactor(studio): share timeline drop decisions and fixtures

* fix(studio): open an empty audio zone below visual tracks

* fix(studio): cancel thumbnails when project pages leave

* refactor(studio): share thumbnail regression setup

* test(studio): gate thumbnail socket release in browser CI

* chore(studio): keep optimistic revision comments within ratchet

* fix(studio): pin regression proxy requests to its backend

* test(studio): bound the proxy origin probe

* test(studio): probe proxy origin through the ready document
2026-10-02 08:04:29 -07:00

12 lines
373 B
TypeScript

import type { ServerResponse } from "node:http";
export function bindNodeRequestSignal(response: ServerResponse): {
signal: AbortSignal;
dispose: () => void;
} {
const controller = new AbortController();
const abort = () => controller.abort();
response.once("close", abort);
return { signal: controller.signal, dispose: () => response.off("close", abort) };
}