slice-generator

Generate FSD-compliant slice boilerplates with configurable segments and layer aliases.

4|Updated Jan 13, 2026
One-click install
npx skills add https://github.com/jhlee0409/claude-plugins --skill slice-generator
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: slice-generator
Source: https://github.com/jhlee0409/claude-plugins/tree/main/plugins/fsd-architect/skills/slice-generator
Command: npx skills add https://github.com/jhlee0409/claude-plugins --skill slice-generator

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Slice boilerplate generation for FSD patterns is automated to standardize project scaffolding across layers and slices, reducing manual setup and style drift.

Core Features & Use Cases

  • Automatically scaffold FSD slices across layers (features, entities, widgets, pages) with configurable segments (ui, model, api, lib)
  • Enforce security-conscious naming and segment rules to prevent invalid paths and hidden files
  • Respect project configuration (.fsd-architect.json) and layer aliases to produce correct filesystem paths
  • Use case: quickly create a new 'auth' slice in features with all standard segments and a ready-to-extend API/Store

Quick Start

Run the slice-generator to scaffold a new slice. Example: slice-generator --layer features --slice auth --segments ui model api lib

Frequently Asked Questions about slice-generator

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

FAQPage Schema
How do I generate FSD slice boilerplates automatically?

To generate FSD slice boilerplates, run the slice-generator with a specified layer and slice name. It reads project configuration to automatically produce consistent paths, segments, and templates into a complete folder structure.

What is the best way to scaffold a Feature-Sliced Design architecture?

Scaffolding a Feature-Sliced Design architecture is best handled by automating slice creation across validated layers like features, entities, widgets, and pages. This enforces security-conscious naming rules and standardizes segments to prevent style drift.

Can I use custom segments like ui and api when scaffolding FSD slices?

Yes, you can use custom segments when scaffolding FSD slices by passing them as arguments. The generator applies these segments alongside validated layers to produce the correct filesystem paths and templates.

Does the FSD slice generator require a specific configuration file?

The FSD slice generator loads a `.fsd-architect.json` configuration file to respect project-specific settings and layer aliases. If absent, it applies sensible defaults to ensure consistent path generation.

Why does slice generation fail with invalid path names?

Slice generation fails with invalid path names because the generator implements input sanitization for names and segments. This security-conscious mechanism prevents invalid paths and hidden files during FSD slice scaffolding.

How do I create a new auth slice in the features layer?

To create a new auth slice in the features layer, execute the generator with the layer and slice arguments. It scaffolds the slice with standard segments like ui, model, api, and lib, ready to extend.