thedaviddias/front-end-checklist

code-splitting

Use when reviewing large SPA bundles, new dependency additions, or routes that feel slow to hydrate. Focus on code that is not required for the initial view and can move behind route transitions, user interaction, or viewport-based loading.

First seen Jun 7, 2026

Installation

$ npx skills add thedaviddias/front-end-checklist --skill code-splitting

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from thedaviddias/front-end-checklist · top by installs.

npx skills add thedaviddias/front-end-checklist

Browse all from thedaviddias/front-end-checklist

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Repository health

Stars 74.1K
License MIT
Default branch main
Open issues 5
Status Active

Skill metadata

Parsed from SKILL.md frontmatter.

More metadata
category
javascript
priority
high
difficulty
intermediate
estimatedTime
25
source
frontendchecklist.io
url
https://frontendchecklist.io/en/rules/javascript/code-splitting

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 1,977 B
  • docs SUMMARY.md 262 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 13 installs

SKILL.md

Split large JavaScript bundles

A 500 KB JavaScript bundle blocks page interactivity for 3–5 seconds on a mid-range mobile device even after the bytes arrive — JS must be parsed and compiled before execution. Code splitting means users only download and parse the code they actually need for the current page, dramatically improving Time to Interactive.

Quick Reference

  • Use dynamic import() to load code only when it's actually needed
  • Split routes in SPAs so each page loads only its own code
  • Lazy-load heavy third-party libraries (chart libraries, rich text editors)
  • Analyze your bundle with a visualizer to find what to split

Check

Identify any large third-party imports or feature modules in this file that could be loaded lazily with dynamic import() instead of statically.

Fix

Convert the identified static imports to dynamic imports using import() and add appropriate loading states.

Explain

Explain JavaScript code splitting, how dynamic import() works, and how to implement route-based splitting in a SPA.

Code Review

Inspect route modules, heavy feature imports, and third-party libraries loaded on initial render. Flag dependencies that can move behind import(), route boundaries, or user-triggered flows without breaking the first meaningful paint.


For full implementation details, code examples, and framework-specific guidance, see references/rule.md.

Rule page: https://frontendchecklist.io/en/rules/javascript/code-splitting