(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
| //http://www.w3.org/TR/2011/WD-page-visibility-20110602/ | |
| (function () { | |
| "use strict"; | |
| //no need to shim if it's already there | |
| if ( 'hidden' in document && 'onvisibilitychange' in document ) { | |
| return; | |
| } | |
| //fail silently if the browser sux |
| // This event emitter emits events, but reserves the right to publish events to | |
| // for its creator. It uses a WeakMap for true encapsulation. | |
| const eesToEventMaps = new WeakMap(); | |
| export default class EventEmitter { | |
| constructor(publisher) { | |
| const eventMap = Object.create(null); | |
| eesToEventMaps.set(this, eventMap); |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
and a potential refactor that could fix that
This is a list of issues and confusions I've encountered with node streams, and things I wish were designed and implemented differently. If promise-streams is ever going to change to a design that doesn't build on top of node streams, this would be a list of mistakes to avoid
enc parameter - Why is encoding always passed together with the data? It should be a separate concern. It doesn't even make sense in objectMode| "You have time you can control and time you can't, | |
| you can't devote all of the time you can control to | |
| new features otherwise the that time shrinks to 0." | |
| -- reconbot | |
| ┌───────── | |
| │ ┌──── | |
| │ │ | |
| │ │ ▲ |