toverux / expresse

ExpreSSE: A better module for working with Server-Sent Events in Express
MIT License
48 stars 7 forks source link

Need Sample Code #5

Closed Arrow66 closed 5 years ago

Arrow66 commented 5 years ago

I've been trying to make example code work for the past couple of hours .but couldn't make it work .I dont have much experience with node js .If possible can you provide some more like noob friendly example code . I'm stuck at someModule.on('someEvent', (event) => {

Does this someModule needs to be an event emitter ?

hope you reply to this

toverux commented 5 years ago

Hello,

No, it doesn't have to be an event emitter. Better, this is just a pure example. You can feed req.sse the way you want. Just... call it, giving it the data you want to stream. However, we're on GitHub here, your question is about the language itself, it is a very generic question about programming, not about the library. It's okay, but you need to ask this kind of things on StackOverflow or similar.

On GitHub, in a general way, please only report bug reports, feature requests, or very specific questions :)