Skip to content
forcedotcom avatar

Design Systems Slds2 Migrate

Migrate LWC styles from SLDS 1 to SLDS 2 by running the linter and fixing hook violations.

CCM score
75 of 100
skills.sh installs
5.8K
GitHub stars
1.2K
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers all styling hook categories: color, spacing, sizing, typography, borders, radius, and shadows
  • Includes four rule guides for no-hardcoded-values-slds2, lwc-token-to-slds-hook, no-slds-class-overrides, and no-deprecated-tokens-slds1
  • Enforces fallback values on every hook and requires paired CSS and markup changes for class overrides
  • Designed for teams running the SLDS linter on Lightning Web Components that need a reference-driven migration workflow

Install

$ npx -y skills add forcedotcom/sf-skills --skill design-systems-slds2-migrate -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Goal

Systematically migrate Lightning Web Components from SLDS 1 to SLDS 2 using the SLDS linter and structured guidance for fixing violations across all styling hook categories.

SLDS 2 Styling Hook Categories

CategoryHook PrefixWhat It Replaces
Color--slds-g-color-*Hardcoded colors, --lwc-color* tokens
Spacing--slds-g-spacing-*Hardcoded margins, padding, gaps
Sizing--slds-g-sizing-*Hardcoded widths, heights, dimensions
Typography--slds-g-font-*Hardcoded font sizes, weights, line heights
Border/Radius--slds-g-radius-border-*, --slds-g-sizing-border-*Hardcoded border-radius, border-width
Shadow--slds-g-shadow-*Hardcoded box-shadow values

Color hooks require the most judgment (context-dependent selection). Non-color hooks are mostly numbered scales with straightforward mappings.

Prerequisites

  • Node.js 14.x or higher installed
  • Access to component CSS and markup files (.html for LWC, .cmp for Aura)
  • Terminal/command line access to run linter
  • Git repository for backup (recommended)

Workflow

Details

Repository
github.com/forcedotcom/sf-skills
Categories
Frontend & UI Code, Design & UI/UX
First seen
Jul 14, 2026

Questions

What does the design-systems-slds2-migrate skill do?

It migrates Lightning Web Components from SLDS 1 to SLDS 2 by running the SLDS linter and fixing the violations it reports. It covers styling hook categories including color, spacing, sizing, typography, borders, radius, and shadows, replacing hardcoded values and deprecated tokens with SLDS 2 styling hooks.

Who should use the design-systems-slds2-migrate skill?

It is for developers who need to uplift existing Lightning Web Components to SLDS 2, especially when they mention linter violations, LWC token migration, class overrides, or hardcoded CSS values. It requires Node.js 14.x or higher, access to component CSS and markup files, and terminal access to run the linter.

How do I install the design-systems-slds2-migrate skill?

Run npx -y skills add forcedotcom/sf-skills --skill design-systems-slds2-migrate -y in your project. Once installed, the agent can run the SLDS linter, fix violations by type, and re-run the linter until it reports zero errors.

Where does this skill stand in the Frontend and UI Code category?

It is listed in the Frontend and UI Code category on Claude Marketplaces, alongside skills such as vercel-react-best-practices, web-design-guidelines, and design-taste-frontend. It sets itself apart by focusing specifically on the SLDS 1 to SLDS 2 styling hook migration for Lightning Web Components.

More from forcedotcom/sf-skills

All 78

Similar to Design Systems Slds2 Migrate

More Frontend & UI Code