@dmail/thenable

2.0.0 • Public • Published

Thenable

npm build codecov

Minimalist promise helpers

Example

import { sequenceFunctions } from "@dmail/thenable"

const promise = sequenceFunctions(
	() => Promise.resolve(10),
	(value) => Promise.resolve(value + 2),
	(value) => value / 2,
)

promise.then((value) => {
	console.log(value) // logs 6
})

Check the API documentation

Readme

Keywords

none

Package Sidebar

Install

npm i @dmail/thenable

Weekly Downloads

2

Version

2.0.0

License

MIT

Last publish

Collaborators

  • dmail