Skip to content

[frontend-perf] Sprint 4 — bundle hygiene: mock out of entry, lazy wizard, drop dead dep #85

Description

@Santisoutoo

Part of VforVitorio#875 (Fable-5 frontend perf audit 2026-07-05). Sprint 4 — Bundle hygiene.

  • S4.1 perf(bundle): mock API out of the live entry + extract applyChunk [S]lib/api.ts:23,60 statically composes mockApi (api.mock.ts ~25KB + mock-data.ts ~22KB source) into the entry of live builds; ChatPage.tsx:21 also imports applyChunk from api.mock. AC: env-gated dynamic import of the mock; extract the pure applyChunk (api.mock.ts:624-642) into its own module. (P3)
  • S4.2 perf(bundle): lazy-load ModelWizard body behind the gate [S] — ModelWizard (27.7KB source) is eager in the entry (main.tsx:18, ModelWizard.tsx:77-107) but renders only pre-onboarding. AC: lazy-load the wizard body behind the gate boolean (the gate stays eager). Note: TutorialTour-eager is the known perf(app): shrink the entry bundle — lazy routes, vendor chunks, lazy tutorial VforVitorio/LexFlow#712 remaining item — do NOT re-file it here. (P3)
  • S4.3 chore(deps): remove dead @xyflow/react [S] — zero imports since [ux] Graph: adopt react-force-graph (2D-canvas + 3D) — replace flat react-flow, supersedes #569 VforVitorio/LexFlow#596 moved to react-force-graph-2d (frontend/package.json:33); not bundled, but install/audit weight. AC: drop the dependency. (P3)

Full detail: memory/fable_frontend_perf_audit_2026-07-05.md.


Upstream: VforVitorio#879

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent:blockedTwo agent-loop attempts failed; needs a humanarea: frontendReflex pages and componentsenhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions