@pagedip/lib-observer
Advanced tools
Comparing version 1.0.0-rc.1 to 1.0.0-rc.2
@@ -20,6 +20,8 @@ 'use strict'; | ||
Event.isEvent = function isEvent(e) { | ||
return e instanceof Event; | ||
return e != null && e["__pagedip_observer_event__"] === true; | ||
}; | ||
Object.assign(Event.prototype, { | ||
["__pagedip_observer_event__"]: true, | ||
stopPropagation() { | ||
@@ -90,3 +92,3 @@ this.bubbles = false; | ||
Observer.isObserver = function isObserver(e) { | ||
return e instanceof Observer; | ||
return e != null && e["__pagedip_observer__"] === true; | ||
}; | ||
@@ -97,2 +99,4 @@ | ||
Object.assign(Observer.prototype, { | ||
["__pagedip_observer__"]: true, | ||
mount(parent) { | ||
@@ -99,0 +103,0 @@ if (!Observer.isObserver(parent)) { |
{ | ||
"name": "@pagedip/lib-observer", | ||
"version": "1.0.0-rc.1", | ||
"version": "1.0.0-rc.2", | ||
"author": "Tyler Johnson <tyler@beneaththeink.com>", | ||
@@ -29,3 +29,3 @@ "repository": { | ||
], | ||
"gitHead": "b2f6e2641c6ca6774ccbb8c492561fa79a664ffa" | ||
"gitHead": "20d1714a1f559939d8e305eca819818169c894e4" | ||
} |
6164
172