strict-async-await-usage

Installation
SKILL.md

Summary

Use async and await for all asynchronous operations. Do not use Promise chaining (.then(), .catch()) unless absolutely necessary (e.g., in a legacy library callback integration).

Rationale

  • Readability: async/await reads like synchronous code, making control flow (loops, conditionals) easier to follow.
  • Error Handling: try/catch provides a single, consistent mechanism for error handling that works for both sync and async errors.
  • Stack Traces: Modern JS engines often provide better stack traces for async functions than for Promise chains.

Guidance

  1. Convert Chains: Flatten .then() chains into sequential lines.
  2. Try/Catch: Wrap fallible async calls in try/catch blocks.
  3. Top-Level: Use Top-Level Await if the environment supports it, rather than an IIFE with .then().

Examples

Installs
1
First Seen
Apr 5, 2026
strict-async-await-usage — mew-ton/coding-guidelines