code: function _VirtualDom_applyEvents(domNode, eventNode, events)
  {
  	var allCallbacks = domNode.elmFs || (domNode.elmFs = {});
  
  	for (var key in events)
  	{
  		var newHandler = events[key];
  		var oldCallback = allCallbacks[key];
  
  		if (!newHandler)
  		{
  			domNode.removeEventListener(key, oldCallback);
  			allCallbacks[key] = undefined;
  			continue;
  		}
  
  		if (oldCallback)
  		{
  			var oldHandler = oldCallback.__handler;
  			if (oldHandler.$ === newHandler.$)
  			{
  				oldCallback.__handler = newHandler;
  				continue;
  			}
  			domNode.removeEventListener(key, oldCallback);
  		}
  
  		oldCallback = _VirtualDom_makeCallback(eventNode, newHandler);
  		domNode.addEventListener(key, oldCallback,
  			_VirtualDom_passiveSupported
  			&& { passive: __VirtualDom_toHandlerInt(newHandler) < 2 }
  		);
  		allCallbacks[key] = oldCallback;
  	}
  }
docs: APPLY EVENTS