await-to-js
- Version 3.0.0
- Published
- 1.16 MB
- No dependencies
- MIT license
Install
npm i await-to-js
yarn add await-to-js
pnpm add await-to-js
Overview
Async/await wrapper for easy error handling in js
Index
Functions
Functions
function to
to: <T, U = Error>( promise: Promise<T>, errorExt?: object) => Promise<[U, undefined] | [null, T]>;
Parameter promise
Parameter errorExt
Additional Information you can pass to the err object { Promise }
Package Files (1)
Dependencies (0)
No dependencies.
Dev Dependencies (26)
- @types/jest
- @types/node
- colors
- commitizen
- coveralls
- cross-env
- cz-conventional-changelog
- husky
- jest
- lint-staged
- lodash.camelcase
- prompt
- replace-in-file
- rimraf
- rollup
- rollup-plugin-commonjs
- rollup-plugin-node-resolve
- rollup-plugin-sourcemaps
- semantic-release
- ts-jest
- ts-node
- tslint
- tslint-config-standard
- typedoc
- typescript
- validate-commit-msg
Peer Dependencies (0)
No peer dependencies.
Badge
To add a badge like this oneto your package's README, use the codes available below.
You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/await-to-js
.
- Markdown[![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/await-to-js)
- HTML<a href="https://www.jsdocs.io/package/await-to-js"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>
- Updated .
Package analyzed in 785 ms. - Missing or incorrect documentation? Open an issue for this package.