# scopsy/await-to-js

Async await wrapper for easy error handling without try-catch

Repository: https://github.com/scopsy/await-to-js
Canonical: https://ross.abutalabs.com/products/await-to-js
Homepage: http://blog.grossman.io/how-to-write-async-await-without-try-catch-blocks-in-javascript/
Language: TypeScript
License: MIT
License Family: permissive
Topics: async, async-await, es2017, try-catch
Last push: 2024-02-07T06:14:12+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 3544, "days_push": 938, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3357, forks 154 (observed 2026-08-28T04:07:57.977246+00:00)

## What it is
await-to-js is a tiny TypeScript utility library that wraps promises in an async/await-friendly helper, returning [error, data] tuples instead of throwing. It lets developers handle async errors without try-catch blocks.

## Use cases
- handle async errors without try-catch
- avoid try-catch boilerplate in async functions
- get error and result from a promise as a tuple
- write cleaner async/await error handling in node
- use go-style error handling in javascript
- type-safe promise error handling in typescript

## When to choose
- you write lots of async/await code and dislike nested try-catch blocks
- you want a tiny, zero-dependency, typed utility for promise error handling
- you prefer Go-style [err, value] patterns in JavaScript or TypeScript

## When to avoid
- you prefer standard try-catch semantics or need stack traces preserved exactly
- your codebase relies on thrown errors propagating through middleware
- you need promise cancellation or advanced async control flow

## Facets
- artifact type: library
- maturity: stable
- function: error-handling, concurrency
- domain: developer-tools, web-development, backend
- platform: cross-platform
- tags: async-await, try-catch, es2017, promise, error-handling, utility, nodejs, javascript, typescript

## Member repositories
- scopsy/await-to-js (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:57.977246+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:40:54.917646+00:00, confidence not recorded.
  - readme: https://github.com/scopsy/await-to-js (fetched 2026-08-28T04:07:57.977246+00:00, sha f77666aff85a)
  - registry_npm: https://registry.npmjs.org/await-to-js (fetched 2026-08-29T09:34:03.143307+00:00, sha dd3db9460e64)
- Data as of 2026-08-30T08:39:29.467469+00:00.
