new-module

Scaffold a NestJS module with GraphQL resolver or REST controller under src/modules.

30|3|Updated Mar 8, 2020
One-click install
npx skills add https://github.com/uxname/liteend --skill new-module-uxname
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: new-module
Source: https://github.com/uxname/liteend/tree/main/.agents/skills/new-module
Command: npx skills add https://github.com/uxname/liteend --skill new-module-uxname

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Scaffolds a new NestJS business module in the project following the repository's file structure, naming, and import conventions, ensuring consistency across modules.

Core Features & Use Cases

  • Generates a complete module skeleton including <name>.module.ts, <name>.service.ts, and optional <name>.resolver.ts or <name>.controller.ts based on your choice.
  • Creates a kebab-case directory under src/modules/<name>/ and aligns file naming with the project's conventions.
  • Provides templates for tests and guides you through AppModule registration for seamless integration.

Quick Start

Provide the module name and whether it should expose a GraphQL resolver, a REST controller, or both, then run the skill to scaffold the module.

Frequently Asked Questions about new-module

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

FAQPage Schema
How do I scaffold a NestJS module with REST and GraphQL?▼

To scaffold a NestJS module, you provide the module name and endpoint preferences. The tool then generates a module skeleton under src/modules/ with optional REST controllers or GraphQL resolvers.

Can I automatically generate tests and AppModule registration for a new NestJS module?▼

Yes, automatic test generation and AppModule registration are supported. The scaffolder provides test templates and guides you through registering the new module in AppModule for seamless integration.

How do I generate a NestJS module that follows existing project conventions?▼

Generating a convention-compliant NestJS module requires specifying your module name. The tool creates a kebab-case directory and aligns file naming with existing import path aliasing and project conventions.

What is the best way to structure a new NestJS business module?▼

The best way to structure a NestJS business module is using a scaffolder to create a standardized skeleton. It generates <name>.module.ts and <name>.service.ts files, ensuring consistency across your modules.

Does the NestJS module scaffolder support both controllers and resolvers in one module?▼

Yes, the NestJS module scaffolder supports adding both a REST controller and a GraphQL resolver. You simply select both endpoint preferences when running the module generation command.