用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/ForceInjection/domain-driven-design-skills --skill feature-scaffolding命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | feature-scaffolding |
| description | BoxLogの新しいFeatureモジュールを作成。stores, hooks, components, types の統一構造を生成。 |
BoxLogプロジェクトの新しいFeatureモジュールを規約に沿って作成するスキルです。
以下のキーワードが含まれる場合に自動的に起動:
src/features/{feature-name}/
├── index.ts # Public API(バレルファイル)
├── types/
│ └── index.ts # 型定義
├── stores/
│ └── index.ts # Zustand stores
├── hooks/
│ └── index.ts # カスタムフック
├── components/
│ └── index.ts # UIコンポーネント
├── constants/ # (optional)
│ └── index.ts
└── contexts/ # (optional)
└── {Feature}Context.tsx
FEATURE_NAME="your-feature"
mkdir -p src/features/${FEATURE_NAME}/{types,stores,hooks,components}
// {Feature}の型定義
export interface {Entity} {
id: string
user_id: string
// entity fields
created_at: Date
updated_at: Date
}
export interface Create{Entity}Input {
// required fields for creation
}
export interface Update{Entity}Input {
// optional fields for update
}
export { use{Feature}Store } from './use{Feature}Store'
import { create } from 'zustand'
import { devtools, persist } from 'zustand/middleware'
interface {Feature}State {
// state
items: {Entity}[]
// actions
addItem: (item: Create{Entity}Input) => Promise<boolean>
updateItem: (id: string, updates: Update{Entity}Input) => Promise<boolean>
deleteItem: (id: string) => Promise<boolean>
getItemById: (id: string) => {Entity} | undefined
}
export const use{Feature}Store = create<{Feature}State>()(
devtools(
persist(
(set, get) => ({
: [],
: (data) => {
},
: (id, updates) => {
},
: (id) => {
},
: {
()..( item. === id)
},
}),
{
: ,
: ({ : state. }),
}
),
{ : }
)
)
export { use{Feature}s } from './use-{feature}s'
export { use{Feature}Operations } from './use-{feature}-operations'
export { {Feature}List } from './{Feature}List'
export { {Feature}Item } from './{Feature}Item'
/**
* {Feature} Feature - Public API
*
* @example
* ```tsx
* // ✅ 推奨: バレルファイル経由
* import { {Feature}List, use{Feature}s, use{Feature}Store } from '@/features/{feature}'
*
* // ❌ 非推奨: 深いパス指定
* import { {Feature}List } from '@/features/{feature}/components/{Feature}List'
* ```
*/
// Components
export { } from './components'
// Hooks
export { } from './hooks'
// Stores
export { use{Feature}Store } from './stores'
// Types
export type { } from './types'
| 種類 | 命名規則 | 例 |
|---|---|---|
| ディレクトリ | kebab-case | user-settings |
| コンポーネント | PascalCase | UserSettingsList |
| フック | camelCase (use prefix) | useUserSettings |
| ストア | camelCase (use prefix) | useUserSettingsStore |
| 型 | PascalCase | UserSettings |
index.ts 経由types/index.ts に集約export function 形式(export default 禁止)bg-card, text-foreground 等)src/features/
├── tags/ # 参考実装(最も完成度が高い)
├── plans/ # 複雑なFeatureの例
├── calendar/ # 大規模Featureの例
├── settings/ # シンプルなFeatureの例
└── auth/ # 認証関連