You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A collection of Roslyn C# source generators for .NET that eliminate boilerplate code and improve developer productivity.
3
+
A collection of Roslyn C# source generators for .NET that eliminate boilerplate code and improve developer productivity. All generators are designed with **Native AOT compatibility** in focus, enabling faster startup times, smaller deployment sizes, and optimal performance for modern cloud-native applications.
4
4
5
5
## 🚀 Source Generators
6
6
@@ -9,6 +9,34 @@ A collection of Roslyn C# source generators for .NET that eliminate boilerplate
9
9
-**[🗺️ MappingGenerator](#️-mappinggenerator)** - Automatic object-to-object mapping with type safety
10
10
-**[🔄 EnumMappingGenerator](#-enummappinggenerator)** - Automatic enum-to-enum mapping with intelligent matching
11
11
12
+
## 📦 Installation
13
+
14
+
All generators are distributed in a single NuGet package. Install once to use all features.
15
+
16
+
**Required:**
17
+
```bash
18
+
dotnet add package Atc.SourceGenerators
19
+
```
20
+
21
+
**Optional (recommended for better IntelliSense):**
**Note:** The generator emits fallback attributes automatically, so the Annotations package is optional. However, it provides better XML documentation and IntelliSense. If you include it, suppress the expected CS0436 warning: `<NoWarn>$(NoWarn);CS0436</NoWarn>`
39
+
12
40
---
13
41
14
42
### ⚡ DependencyRegistrationGenerator
@@ -93,34 +121,6 @@ public class EmailService : IEmailService, INotificationService { }
93
121
publicclassReportService : IReportService { }
94
122
```
95
123
96
-
#### 📦 Installation
97
-
98
-
**Required:**
99
-
```bash
100
-
dotnet add package Atc.SourceGenerators
101
-
```
102
-
103
-
**Optional (recommended for better IntelliSense):**
**Note:** The generator emits fallback attributes automatically, so the Annotations package is optional. However, it provides better XML documentation and IntelliSense. If you include it, suppress the expected CS0436 warning: `<NoWarn>$(NoWarn);CS0436</NoWarn>`
121
-
122
-
See the [complete guide](docs/generators/DependencyRegistration.md) for multi-project setups.
**Note:** The generator emits fallback attributes automatically, so the Annotations package is optional. However, it provides better XML documentation and IntelliSense. If you include it, suppress the expected CS0436 warning: `<NoWarn>$(NoWarn);CS0436</NoWarn>`
305
-
306
280
#### 🛡️ Compile-Time Safety
307
281
308
282
| ID | Description |
@@ -399,6 +373,7 @@ var dtos = users.Select(u => u.MapToUserDto()).ToList();
399
373
-**🪆 Nested Object Mapping**: Automatically chains mappings for nested properties
**Note:** The generator emits fallback attributes automatically, so the Annotations package is optional. However, it provides better XML documentation and IntelliSense. If you include it, suppress the expected CS0436 warning: `<NoWarn>$(NoWarn);CS0436</NoWarn>`
488
-
489
438
#### 🔁 Multi-Layer Architecture
490
439
491
440
Perfect for 3-layer architectures:
@@ -659,32 +608,6 @@ var dto = entity.MapToStatusDto(); // StatusDto.Unknown
**Note:** The generator emits fallback attributes automatically, so the Annotations package is optional. However, it provides better XML documentation and IntelliSense. If you include it, suppress the expected CS0436 warning: `<NoWarn>$(NoWarn);CS0436</NoWarn>`
687
-
688
611
#### 🛡️ Compile-Time Safety
689
612
690
613
Get errors and warnings at compile time, not runtime:
0 commit comments