{"repo":"dioKaratzas/fluent-dto-macro","free":true,"listed":false,"github":"https://github.com/dioKaratzas/fluent-dto-macro","clone":"git clone https://github.com/dioKaratzas/fluent-dto-macro.git","description":"A Swift macro that simplifies handling Vapor Fluent models in API responses by auto-generating type-safe content structures, reducing boilerplate while keeping a clean separation between database models and API layers. 🚀","language":"Swift","stars":21,"topics":["automation","fluent","macros","swift","swift-macros","vapor","fluent-kit","fluent-dto"],"license":"MIT","category":"workflow-automation","readme_excerpt":"FluentDTO Note : The package was renamed from FluentContentMacro to FluentDTOMacro shortly after initial release to better reflect its purpose. If you were one of the early adopters, please update your package references and macro usage accordingly. 📖 Overview A Swift macro that simplifies how you handle Vapor Fluent models in your API responses. It automatically generates clean, type-safe DTOs, eliminating boilerplate while maintaining a clear separation between your database models and API layer. ✨ Features - 🚀 Reduced Boilerplate - Automatic DTO generation with a simple macro - 🔒 Type Safety - Compile-time validation of your model-to-DTO mappings - 🎯 Selective Fields - Control which properties are exposed in your DTOs - 🔄 Relationship Support - Automatically handles nested Fluent relationships - 🧵 Concurrency Ready - Generated DTOs automatically conform to Sendable - 🛠️ Customizable - Configure access levels, mutability, and protocol conformance - 🔒 Security First - Easy exclusion of sensitive fields - 🎨 Clean Architecture - Clear separation of database and API concerns 📦 Installation Add the following dependency to your Package.swift : Then add the macro to your target's dependencies: 🚀 Getting Started 1️⃣ Import the package: 2️⃣ Add the macro to your model: 3️⃣ Use the generated DTO: ⚙️ Configuration Relationship Control Choose which relationships to include in your DTOs: Immutability Control property mutability: Access Control Set visibility levels: Field Exc","default_branch":null,"files":null,"tree":[],"storefront":"/r/dioKaratzas","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/dioKaratzas/fluent-dto-macro/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}