Skip to content
This repository has been archived by the owner on Oct 31, 2024. It is now read-only.

Commit

Permalink
doc: event emitter docs
Browse files Browse the repository at this point in the history
  • Loading branch information
mzahor committed Mar 25, 2020
1 parent cfd89b4 commit 9b1d7a8
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,14 @@ consumer.start();

## Events and logging

SqsConsumer has an [EventEmitter](https://nodejs.org/api/events.html) and send the following events:
SqsConsumer has an internal [EventEmitter](https://nodejs.org/api/events.html), you can subscribe for events like this:
```ts
sqsConsumer.on(SqsConsumerEvents.messageProcessed, () => {
// ...
});
```

It sends the following events:

| Event | Params | Description |
| ------------------- | ---------------- | ----------------------------------------------------------------------------------- |
Expand Down

0 comments on commit 9b1d7a8

Please sign in to comment.