File tree Expand file tree Collapse file tree 1 file changed +17
-2
lines changed Expand file tree Collapse file tree 1 file changed +17
-2
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,10 @@ Official CloudEvents' SDK for JavaScript.
12
12
13
13
Before create an awesome PR, please read our [ guidelines] ( ./CONTRIBUTING.md ) .
14
14
15
+ ## Examples
16
+
17
+ To see working examples, point to [ examples] ( ./examplpes ) .
18
+
15
19
## Versioning
16
20
17
21
### Before Spec reaches 1.0
@@ -165,8 +169,19 @@ binding.emit(cloudevent)
165
169
console .error (err);
166
170
});
167
171
```
172
+ #### Receiving Events Using Express
173
+
174
+ See how to listen to events using
175
+ [ express] ( https://github.com/expressjs/express ) .
176
+
177
+ ``` js
178
+
179
+
180
+ ```
181
+
182
+ #### Receiving Using our Simple HTTP Server
168
183
169
- #### Receiving
184
+ See how to listen to events using out simple http server.
170
185
171
186
``` js
172
187
var Cloudevent = require (" cloudevents-sdk" );
@@ -181,7 +196,7 @@ var config = {
181
196
// The binding instance
182
197
var binding = new Cloudevent.bindings [" http-structured0.2" ](config);
183
198
184
- binding .receive ()
199
+ binding .listen ()
185
200
.then (cloudevent => {
186
201
// do something with event
187
202
})
You can’t perform that action at this time.
0 commit comments