csharp-async by github/awesome-copilot
npx skills add https://github.com/github/awesome-copilot --skill csharp-async您的目标是帮助我遵循 C# 中异步编程的最佳实践。
GetData() 对应 GetDataAsync())Task<T>TaskValueTask<T> 以减少内存分配void,事件处理程序除外ConfigureAwait(false) 以防止库代码中的死锁广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
Task.FromException() 传播异常,而不是在返回 Task 的异步方法中抛出异常Task.WhenAll() 并行执行多个任务Task.WhenAny() 来实现超时或获取第一个完成的任务.Wait()、.Result 或 .GetAwaiter().GetResult()在审查我的 C# 代码时,请识别这些问题,并建议遵循这些最佳实践的改进方案。
每周安装量
7.5K
仓库
GitHub 星标数
26.7K
首次出现
2026年2月25日
安全审计
安装于
codex7.4K
gemini-cli7.4K
opencode7.3K
github-copilot7.3K
cursor7.3K
amp7.3K
Your goal is to help me follow best practices for asynchronous programming in C#.
GetDataAsync() for GetData())Task<T> when the method returns a valueTask when the method doesn't return a valueValueTask<T> for high-performance scenarios to reduce allocationsvoid for async methods except for event handlersConfigureAwait(false) when appropriate to prevent deadlocks in library codeTask.FromException() instead of throwing in async Task returning methodsTask.WhenAll() for parallel execution of multiple tasksTask.WhenAny() for implementing timeouts or taking the first completed task.Wait(), .Result, or .GetAwaiter().GetResult() in async codeWhen reviewing my C# code, identify these issues and suggest improvements that follow these best practices.
Weekly Installs
7.5K
Repository
GitHub Stars
26.7K
First Seen
Feb 25, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
codex7.4K
gemini-cli7.4K
opencode7.3K
github-copilot7.3K
cursor7.3K
amp7.3K
97,600 周安装