console-frontend-review_skill

This skill performs focused frontend code reviews for the depot console, enhancing WebSocket teleop reliability, 3D rendering performance, and state-management
  • Rust

28

GitHub Stars

3

Bundled Files

2 months ago

Catalog Refreshed

4 months ago

First Indexed

Readme & install

Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.

Installation

Preview and clipboard use veilstrat where the catalogue uses aiagentskills.

npx veilstrat add skill ecto/muni --skill console-frontend-review

  • performance.md17.3 KB
  • SKILL.md22.8 KB
  • websocket-protocols.md14.8 KB

Overview

This skill reviews React/TypeScript frontend code for the depot console web application with emphasis on real-time rover teleoperation, state management, WebSocket binary protocols, and 3D visualization. It highlights correctness, performance, and safety across Zustand store architecture, protocol encoding/decoding, and React Three Fiber rendering. Use it to validate changes, find regressions, and recommend concrete fixes for telemetry, input handling, and streaming code.

How this skill works

The review inspects critical files including the Zustand store, binary protocol codec, WebSocket connection hook, video stream hook, and the 3D scene components. It checks for immutable state updates, selector usage to minimize re-renders, correct ArrayBuffer/DataView usage for little-endian binary encoding, proper WebSocket lifecycle and reconnect logic, and safe input/visibility handling. It also evaluates memory management around blob URLs and React Three Fiber performance patterns.

When to use it

  • When reviewing PRs that modify rover teleop, telemetry, or input handling code.
  • When debugging inconsistent telemetry, latency spikes, or command-rate issues.
  • When validating binary WebSocket protocol changes or decoding errors.
  • When optimizing 3D scene performance or diagnosing React Three Fiber bottlenecks.
  • When adding or changing 360° video streaming or blob URL lifecycle handling.

Best practices

  • Use small domain slices in the single Zustand store and selectors to avoid unnecessary re-renders.
  • Keep binary protocol fast: DataView with explicit bounds checks and little-endian reads/writes; avoid JSON in the critical path.
  • Set WebSocket.binaryType = 'arraybuffer', add exponential backoff reconnects, clean up listeners on unmount.
  • Rate-limit command sending (100Hz for twist, 10Hz heartbeat) and stop commands when document.visibilityState is hidden.
  • Avoid storing computed values in the store, revoke blob URLs when replacing frames, and prefer typed interfaces over any.

Example use cases

  • Review a PR that changes encodeTwist/decodeTelemetry to ensure offsets, endianness, and length checks are correct.
  • Audit useRoverConnection to ensure arraybuffer handling, reconnect/backoff, and cleanup are implemented.
  • Optimize Scene.tsx to reduce draw calls, remove unnecessary state subscriptions, and use memoized objects in R3F.
  • Debug a bug where commands continue when tab is backgrounded by checking page visibility handlers and input clearing.
  • Validate useVideoStream for proper blob URL creation/revocation and consistent fps reporting.

FAQ

Selecting the entire Zustand state in components, frequent object allocations in render paths, and using JSON over WebSocket for 100Hz control are the most common issues.

How should binary boundaries be validated?

Always check data.byteLength against expected minimums before reading, verify the message type byte first, and throw or ignore malformed frames.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational
console-frontend-review skill by ecto/muni | VeilStrat