Files
clash-verge-rev/scripts/perf/minimal.ts
T
Tunglies a0ce1cdadf chore(perf): extract replay tooling into a standalone harness (#8645)
* chore(perf): use the external measurement harness

Keep real Traffic, Logs and Connections scenes and the isolated native
entry beside product APIs. Invoke the standalone runner with an explicit
project path and remove bundled measurement orchestration.

Support the optional owned virtual display and read-only isolation
snapshots without changing ordinary product startup or networking.

* docs: scope agent guidance to the active task

Keep behavior and ownership guidance with the relevant task routes,
including the external performance adapter workflow. Preserve focused
self-review for routine changes and independent review where required.

* docs(perf): link the standalone harness repository

Link the harness repository and operating guide, and document first-time
checkout setup while preserving explicit paths for routine invocation.

* fix(perf): account for external harness dependencies in Knip

* chore(perf): keep tool dependencies and guidance outside the product

* docs(perf): keep product guidance focused on the adapter
2026-11-14 06:11:35 +00:00

22 lines
667 B
TypeScript

import { scenario, subscribe } from './replay'
export function mount(root: HTMLElement) {
const rows = Array.from({ length: 20 }, () => {
const row = document.createElement('div')
row.style.cssText = 'height:32px;white-space:nowrap;overflow:hidden'
root.appendChild(row)
return row
})
subscribe(({ payload }) => {
const texts =
scenario === 'logs'
? (payload as ILogItem[]).map((log) => log.payload)
: (payload as IConnections).connections.map(
(connection) => connection.metadata.host,
)
rows.forEach((row, index) => {
row.textContent = texts[index % texts.length] ?? ''
})
})
}