peppa/apps/web/components/Lazy.tsx
peppa-bot d8a37833f3
All checks were successful
peppa/build build: success за 16с
peppa/bundle bundle: success за 0с
peppa/lint lint: success за 1с
peppa/typecheck typecheck: success за 21с
PEP-217: Web Vitals пользователей, проверка веса JS в CI, словари не в браузерном бандле
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-20 17:03:07 +05:00

11 lines
658 B
TypeScript

"use client";
// PEP-217: heavy client pieces that the first view does not need load on demand (next/dynamic,
// ssr off) — they stay out of the first-load JS of every route.
import dynamic from "next/dynamic";
/** Terminal of a runner (xterm.js and its styles): only when a terminal is opened. */
export const LazyRunnerTerminal = dynamic(() => import("@/components/RunnerTerminal").then((m) => m.RunnerTerminal), { ssr: false });
/** ⌘K palette and shortcuts: there is nothing to draw before the first key press. */
export const LazyCommandPalette = dynamic(() => import("@/components/CommandPalette").then((m) => m.CommandPalette), { ssr: false });