Farms: Node JS Tutorial for Beginners #8 - The Node Event Emitter
Productivity | Information | History | View | Quality
Yo gang, in this Node JS tutorial, I'll be introducing you to the event emitter in the Node core. The event emitter allows us to wire up custom events to our own objects and then emit those events at a later point in time. ----- COURSE LINKS: + Repo - https://github.com/iamshaunjp/node-js-playlist + Atom editor - https://atom.io/ --------------------------------------------------------------------------------------------- You can find more front-end development tutorials on CSS, HTML, JavaScript, jQuery, WordPress & more on the channel homepage... SUBSCRIBE TO CHANNEL - https://www.youtube.com/channel/UCW5YeuERMmlnqo4oq8vwUpg?sub_confirmation=1 ========== JavaScript for Beginners Playlist ========== https://www.youtube.com/playlist?list=PL4cUxeGkcC9i9Ae2D9Ee1RvylH38dKuET ============ CSS for Beginners Playlist ============= https://www.youtube.com/playlist?list=PL4cUxeGkcC9gQeDH6xYhmO-db2mhoTSrT ============== The Net Ninja ===================== For more front-end development tutorials & to black-belt your coding skills, head over to - https://www.youtube.com/channel/UCW5YeuERMmlnqo4oq8vwUpg or http://thenetninja.co.uk ================== Social Links ================== Twitter - @TheNetNinja - https://twitter.com/thenetninjauk
Comments
-
util.inherits() seems awfully clunky. Do people still use this notation now that ES6 has more Java-like class syntax? I've always been peeved by the way js uses "function" in place of "class" where there should be made a greater distinction.
-
hey Net Ninja, thanks for this cool course. Although I have a question here... so in the code where we are emitting the event on the James object, by mistake I missed to type the event name and only typed James.emit('learning node js is fun');
and tried to run this via terminal and it didn't gave any o/p later I noticed my mistake and corrected it. So my doubt is isn't node is supposed to give any errors in situations like this?? -
Great series of tuts... Please try to provide React + Redux course also if possible
-
hey guys.. noob question here. I'm getting the message on the command line: The super constructor to "inherits" must not be null or undefined. How do I remedy this?
-
finaly understood events. Thank you.
-
Loving it!
-
I'm getting error : TypeError: Cannot read property 'on' of undefined !!! anyone know what the hell is this ?
-
This is like sending message to multiple clients though events. What if number of events listeners are higher in real time data application. Is above example good enough in terms of performance or should we use socket.io to push messages to client from server end?
-
I'm surprised nobody has screamed misogyny because Mary was underrepresented and not allowed to speak.
-
I realize that this is just a demonstration for the event emitter and the util module, but beginners should know that we can achieve the same result of this example using a much simpler way: Just add a function speak() to the prototype of Person.
-
Went through the whole Nodejs essential training on Lynda which was decent, but I have to say your videos are laid out much better. Cheers pal, subbed.
-
Concise and to the point! Great Job! Subscribed!
-
how would be connect to a database? also is database's like MongoDB secure for personal information, if this was to be transmitted over a mobile application?
-
Great stuff.. very easy to understand --thanks Shaun
-
First, I would love to thank you for all these valuable, simple to understand tutorials.... The Node.js, on the other hand, is extremely hard to understand unless being used in a real-world project.
Can you please try to give us a one-page app example showing us how to include node.js in the interaction process?! -
If I may ask, what are node.js hosting requierments and is there any free hosting supporting node.js? Thanks for tuts.