-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a5c1436
commit 12318cd
Showing
1 changed file
with
8 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,25 +38,25 @@ $ yarn add c-promise2 | |
``` | ||
|
||
#### CDN | ||
- [development UMD version](https://unpkg.com/[email protected]/dist/dev/c-promise.umd.js) | ||
- [development UMD version with ](https://unpkg.com/[email protected]/dist/dev/c-promise.umd.js) | ||
(additional error handling activated) | ||
|
||
- [production UMD version](https://unpkg.com/[email protected]/dist/c-promise.umd.js) | ||
- [production UMD version](https://unpkg.com/[email protected]/dist/c-promise.umd.js) (or [minified](https://unpkg.com/[email protected]/dist/c-promise.umd.min.js) ~9KB) | ||
|
||
- [production CommonJS version](https://unpkg.com/[email protected]/dist/c-promise.cjs.js) | ||
|
||
- [production ESM version](https://unpkg.com/[email protected]/dist/c-promise.mjs) | ||
|
||
## Features / Advantages | ||
- there are no any dependencies (except [native] Promise), browser support | ||
- cancellation sequence | ||
- supports cancellation of the whole chain - rejects the deepest pending promise in the chain | ||
- there are no any dependencies (except [native] Promise) | ||
- browser support | ||
- :fire: supports cancellation of the whole chain - rejects the deepest pending promise in the chain | ||
- supports onCancel event handler to abort some internal work (clear timers, close requests etc.) | ||
- supports built-in signal interface for API that supports it (like fetch method) | ||
- proper handling of manually throwing of the `CanceledError` by the chain | ||
- progress capturing to handle progress of the chain, useful for long-term operations | ||
- proper handling of `CanceledError` errors manually thrown inside the chain | ||
- :fire: progress capturing with result scaling to handle progress of the whole chain (including nested promise chains), useful for long-term operations | ||
- ability to install the `weight` for each promise in the chain | ||
- ability to attach meta info on each setting of the progress | ||
- supports capturing progress and scaling the result of the internal promise chain returned by the `then` method | ||
- the `delay` method to return promise that will be resolved with the value after timeout | ||
- static methods `all`, `race` support cancellation and will cancel all other pending promises after they resolved | ||
- the `catch` method supports error class filtering | ||
|