Skip to content

Commit

Permalink
Fix code in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
yuriyyakym committed Dec 26, 2023
1 parent 1e0edb6 commit bcb3e90
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/docs/about.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ You are not likely to use it directly, the code is just for demonstration purpos
```ts
const event = new AwaiEvent();

setTimeout(event.emit, 100, 'hello');
setTimeout(event.emit, 200, 'awai');
setTimeout(() => event.emit('hello'), 100);
setTimeout(() => event.emit('awai'), 200);

const value1 = await event;
const value2 = await event;
Expand Down
4 changes: 2 additions & 2 deletions docs/docs/awai-event.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ Awai event is a promise-like object which has no terminal state and may resolve
```ts title="Example of AwaiEvent usage"
const event = new AwaiEvent();

setTimeout(event.emit, 100, 'hello');
setTimeout(event.emit, 200, 'awai');
setTimeout(() => event.emit('hello'), 100);
setTimeout(() => event.emit('awai'), 200);

const value1 = await event;
const value2 = await event;
Expand Down

0 comments on commit bcb3e90

Please sign in to comment.