Skip to content

Commit

Permalink
Create README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
dotconnor authored Oct 25, 2018
1 parent e8dda65 commit d86a653
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# defer
Remotely resolve/reject a promise

## Install
```shell
yarn add @a1motion/defer
```

## Usage

```javascript
import defer from "@a1motion/defer";

const promise = defer();
promise.then(() => {
// do things after
})

// somewhere else
promise.resolve();
```

0 comments on commit d86a653

Please sign in to comment.