diff --git a/docs/deployment/trimming.md b/docs/deployment/trimming.md index 67917cd6f..54ecb4396 100644 --- a/docs/deployment/trimming.md +++ b/docs/deployment/trimming.md @@ -1,7 +1,7 @@ --- title: "Trim a .NET MAUI app" description: "Learn about the .NET trimmer, which eliminates unused code from a .NET MAUI app to reduce its size." -ms.date: 12/03/2024 +ms.date: 12/20/2024 no-loc: [ ILLink ] monikerRange: ">=net-maui-9.0" --- @@ -35,8 +35,10 @@ The `full` trim mode removes any code that's not used by your app. The `partial` This is equivalent to setting `[AssemblyMetadata("IsTrimmable", "True")]` when building the assembly. -> [!NOTE] -> It's not necessary to set the `$(PublishTrimmed)` build property to `true` in your app's project file, because this is set by default. +In a .NET MAUI app, it's not necessary to set the `$(PublishTrimmed)` build property to `true` in your app's project file, because this is set by default. + +> [!IMPORTANT] +> Don't set the `$(TrimMode)` build property when using Native AOT deployment. Native AOT deployment automatically performs full trimming of your app. For more information, see [Native AOT deployment on iOS and Mac Catalyst](nativeaot.md). For more trimming options, see [Trimming options](/dotnet/core/deploying/trimming/trimming-options).