dotnet-trimming

Community

Make .NET apps trim-safe.

AuthorAGIBuild
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill helps developers ensure their .NET applications and libraries are compatible with the .NET trimming process, reducing application size and improving performance by removing unused code.

Core Features & Use Cases

  • Annotation: Apply attributes like [RequiresUnreferencedCode] and [DynamicallyAccessedMembers] to guide the trimmer.
  • Preservation: Use ILLink descriptors to explicitly preserve types and members that reflection might otherwise remove.
  • Diagnostics: Configure TrimmerSingleWarn=false for detailed warnings and use IsTrimmable for libraries.
  • Use Case: A library author wants to ensure their library can be safely included in a trimmed application. They would add IsTrimmable=true to their project and annotate any reflection-based APIs.

Quick Start

Configure your application to enable trim analysis during development by setting EnableTrimAnalyzer=true and TrimmerSingleWarn=false in your .csproj file.

Dependency Matrix

Required Modules

None required

Components

references

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: dotnet-trimming
Download link: https://github.com/AGIBuild/Agibuild.Fulora/archive/main.zip#dotnet-trimming

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.