aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.md5
-rw-r--r--package.json2
-rw-r--r--src/index.ts2
3 files changed, 7 insertions, 2 deletions
diff --git a/README.md b/README.md
index 30beefe..c572f4f 100644
--- a/README.md
+++ b/README.md
@@ -21,6 +21,7 @@
- [off](#off)
- [emit](#emit)
- [Contribute](#contribute)
+- [Acknowledments](#acknowledments)
- [License](#license)
## Install
@@ -123,6 +124,10 @@ If present, `"*"` handlers are invoked after type-matched handlers.
If you want to contribute, I would be happy to look in to your PRs.
+# Acknowledments
+
+I would like to thank [Jason Miller](https://jasonformat.com/) (@developit) for developing `mitt`. `nitt` is no more than just `mitt` with a few extras.
+
## License
[MIT License](https://opensource.org/licenses/MIT)
diff --git a/package.json b/package.json
index e28990a..f7e377c 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "nitt",
- "version": "1.0.0",
+ "version": "1.0.1",
"author": "Marin Ivanov <[email protected]>",
"license": "MIT",
"scripts": {
diff --git a/src/index.ts b/src/index.ts
index aa07055..3608ae1 100644
--- a/src/index.ts
+++ b/src/index.ts
@@ -51,7 +51,7 @@ export default function nitt(all: EventHandlerMap) {
* @returns {Promise<any>}
*/
when(type: string): Promise<any> {
- return new Promise<any>(r => this.once(type, r));
+ return new Promise<any>(resolve => this.once(type, resolve));
},
/**