mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-10-26 22:22:13 +08:00
refactor(frontend): drop dead code in traffic and ws pipelines
Removes zero-consumer surface verified by repo-wide grep: the reference-count render machinery, the never-called clearData chain, unread snapshot fields (rangeMinutes, reason), dead refresh callbacks on the connection hooks, the write-only wsRef sync, and the worker's unreachable DEFAULT_CONFIG placeholder (now definite assignment under the init-first client contract). No behavior change; the compressed sampler path, samplerStats diagnostics, and lastTimestamp perf contract stay. Net -120 lines across six files.
This commit is contained in:
@@ -39,17 +39,6 @@ interface StatCardProps {
|
||||
onClick?: () => void
|
||||
}
|
||||
|
||||
// 全局变量类型定义
|
||||
declare global {
|
||||
interface Window {
|
||||
animationFrameId?: number
|
||||
lastTrafficData?: {
|
||||
up: number
|
||||
down: number
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 统计卡片组件 - 使用memo优化
|
||||
const CompactStatCard = memo(
|
||||
({ icon, title, value, unit, color, onClick }: StatCardProps) => {
|
||||
|
||||
Reference in New Issue
Block a user