Loading…
Wraps any throwable sync or async operation and returns a `Result` instead of throwing. Smart overload detection handles raw Promises, async functions, and sync functions uniformly through a single `attempt` entry point. An optional `transform` parameter lets you shape caught errors into typed `Err` values before they reach the caller.