Skip to content

Commit 6f04c21

Browse files
authored
Update README.md
1 parent 64ae9ba commit 6f04c21

File tree

1 file changed

+5
-10
lines changed

1 file changed

+5
-10
lines changed

packages/node/README.md

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
2-
## Warning: Until 1.x release, use this library at your own risk!
1+
# @segment/analytics-node
2+
> ### Warning: Until 1.x release, use this library at your own risk!
33
While the API is very similar, the documentation for the legacy SDK (`analytics-node`) is here: https://segment.com/docs/connections/sources/catalog/libraries/server/node/
44

55
## Requirements
6-
- NodeJS >= 14.x
6+
- Node.js >= 14
77

88
## Quick Start
99
### Install library
@@ -106,12 +106,7 @@ console.log(unflushedEvents) // all events that came in after closeAndFlush was
106106

107107
## Event Emitter
108108
```ts
109-
// listen globally to events
110-
analytics.on('identify', (ctx) => console.log(ctx.event))
111-
112-
// listen for errors (if needed)
109+
// subscribe to delivery errors
113110
analytics.on('error', (err) => console.error(err))
114111

115-
```
116-
117-
112+
// subscribe to a specific event

0 commit comments

Comments
 (0)