frontend-fsd-guard

Enforce Feature-Sliced Design 2.1 import boundaries and public API rules.

Updated Mar 12, 2026
One-click install
npx skills add https://github.com/MithrilMan/neomithril-ui --skill frontend-fsd-guard
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: frontend-fsd-guard
Source: https://github.com/MithrilMan/neomithril-ui/tree/main/.codex/skills/frontend-fsd-guard
Command: npx skills add https://github.com/MithrilMan/neomithril-ui --skill frontend-fsd-guard

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Enforce the FSD 2.1 guidelines during frontend work to maintain correct layer boundaries, stable public APIs, and architecture discipline.

Core Features & Use Cases

  • Ensure imports only travel downwards through layers
  • Prevent cross-slice drift and encourage public APIs
  • Reference repository rules in references/fsd-2.1-rules.md during reviews

Quick Start

Run the Frontend FSD Guard before making structural frontend changes to verify layer boundaries and public API exposure.

Frequently Asked Questions about frontend-fsd-guard

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce Feature-Sliced Design layer boundaries during frontend refactoring?

To enforce Feature-Sliced Design layer boundaries during frontend refactoring, run the FSD guard before structural changes. It checks import paths under src/ and apps/admin-console/src/ to ensure imports travel only downwards through layers and prevent cross-slice drift.

What is the best way to prevent cross-slice import drift in a frontend codebase?

Preventing cross-slice import drift requires checking public API exposure and import boundaries. This skill cross-references repository rules in references/fsd-2.1-rules.md and local AGENTS.md to validate that slices communicate only through their public APIs.

Does the FSD guard work with existing repository guidance and rule files?

Yes, the FSD guard integrates with existing repository guidance. It is explicitly guided by the repository's references/fsd-2.1-rules.md and local AGENTS.md files to enforce architecture-sensitive constraints during code reviews and refactors.

How do I check public API exposure when adding new slices to a frontend project?

To check public API exposure when adding new slices, apply the guard while editing code under src/ directories. It validates adherence to FSD 2.1 rules, ensuring new slices expose stable public APIs and maintain correct architectural layer separation.

When should I run an FSD architecture check during frontend development?

Run an FSD architecture check before making structural frontend changes such as creating new slices, refactoring existing code, or cleaning up import boundaries. This prevents layer drift and ensures public API discipline is maintained proactively.