# Easy Nest Generator

Easy Nest Generator is a powerful library crafted to streamline and accelerate front-end development within NestJS projects. By leveraging automation, it simplifies working with entities and DTO files, ensuring your project remains efficient and maintainable.

## Key Features

- **DRY Principle Compliance**: Automates repetitive tasks, reducing manual effort and ensuring consistency across your codebase.
- **Seamless API Integration**: Simplifies the implementation of API calls for the front-end, keeping interfaces, hooks, and endpoints perfectly aligned with the backend API.
- **Up-to-Date Synchronization**: Ensures that all generated code reflects the latest backend changes, minimizing errors and improving productivity.

## Installation

Install Easy Nest Generator via npm:

```bash
npm install easy-nest-generator
```

### Configuration

First you need an **ngconfig.json** file to declare folders, files for the library to work on

```bash
{
  "rootFilePath": "src",
  "destFilePath": "src/types",
  "entitySourceFolder": "entities",
  "dtoSourceFolder": "dtos",
  "hooksSourceFolder": "hooks",
  "entityDestFileName": "models.d.ts",
  "dtoDestFileName": "dtos.d.ts",
  "hooksDestFileName": "hooks.d.ts"
}

```

## Usage

1. **Setup**: Import the library into your project.
2. **Generate Code**: Use the provided CLI commands to generate entities, DTOs, or other required files.
3. **Integrate**: Connect the generated files with your front-end to enjoy streamlined development.

### Example Command:

```bash
npx nest-gen model
```

**Resuls**: This command will generates all interface for all models you have in **_entitySourceFolder_**

## Benefits

- Saves time by automating routine coding tasks.
- Enhances code quality and maintainability.
- Reduces errors through consistent synchronization between front-end and back-end.

## Contributing

We welcome contributions! If you have ideas or enhancements, feel free to open an issue or submit a pull request.

## License

This project is licensed under the MIT License. See the [LICENSE](./LICENSE) file for details.

---

Start building faster and smarter with Easy Nest Generator today!
