nx-generate
Generate code using Nx generators — scaffold projects, libraries, features, or run workspace-specific generators with proper discovery, validation, and verification. Use when user says "create a new library", "scaffold a component", "generate code with Nx", "run a generator", "nx generate", or any code scaffolding task in a monorepo. Prefers local workspace-plugin generators over external plugins. Do NOT use for running build/test/lint tasks (use nx-run-tasks) or workspace configuration (use nx-workspace).
npx skills add tech-leads-club/agent-skills --skill nx-generate --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Run Nx Generator Nx generators are powerful tools that scaffold projects, make automated code migrations or automate repetitive tasks in a monorepo. They ensure consistency across the codebase and reduce boilerplate work. This skill applies when the user wants to: - Create new projects like libraries or applications - Scaffold features or boilerplate code - Run workspace-specific or custom generators - Do anything else that an nx generator exists for ## Generator Discovery Flow ### Step 1: List Available Generators Use the Nx CLI to discover available generators: - List all generators for a plugin: `npx nx list @nx/react` - View available plugins: `npx nx list` This includes: - Plugin generators (e.g., `@nx/react:library`, `@nx/js:library`) - Local workspace generators (defined in the repo's own plugins) ### Step 2: Match Generator to User Request Based on the user's request, identify which generator(s) could fulfill their needs. Consider: - What artifact type they want to create (library, application, etc.) - Which framework or technology stack is relevant - Whether they mentioned specific generator names **IMPORTANT**: When both a local workspace generator and an external plugi
- Generator Discovery Flow
- Step 1: List Available Generators
- Step 2: Match Generator to User Request
- Pre-Execution Checklist
- 1. Fetch Generator Schema
- 2. Read Generator Source Code
- 2.5 Reevaluate if the generator is right
- 3. Understand Repo Context
- 4. Validate Required Options
- Execution
- Consider Dry-Run (Optional)
- Running the Generator
- Handling Generator Failures
- Post-Generation
npx nx g @nx/react:library --help nx generate <generator-name> <options> --no-interactive nx generate @nx/react:library --name=my-utils --no-interactive nx format --fix nx lint <new-project> nx test <new-project> nx build <new-project>
What does the nx-generate skill do?
Generate code using Nx generators — scaffold projects, libraries, features, or run workspace-specific generators with proper discovery, validation, and verification. Use when user says "create a new library", "scaffold a component", "generate code with Nx", "run a generator", "nx generate", or any code scaffolding task in a monorepo. Prefers local workspace-plugin generators over external plugins. Do NOT use for running build/test/lint tasks (use nx-run-tasks) or workspace configuration (use nx-workspace).
How do I install it?
Run `npx skills add tech-leads-club/agent-skills --skill nx-generate --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From tech-leads-club/agent-skills, a repository with 4,983 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
