From 7b9458fde4726652e8f809fd58f0e4ba28b6cc89 Mon Sep 17 00:00:00 2001 From: Filipe Guerra Date: Wed, 8 Jun 2016 17:07:39 -0700 Subject: [PATCH] Performance should only work for components that are in sidecar mapping --- src/js/inject/sidecar.debug.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/js/inject/sidecar.debug.js b/src/js/inject/sidecar.debug.js index dafb8a8..a2f5fdc 100644 --- a/src/js/inject/sidecar.debug.js +++ b/src/js/inject/sidecar.debug.js @@ -269,6 +269,12 @@ Debug.prototype._onHookLayoutRender = function() { this.$el.attr('data-debug-cid', this.cid); + + if (!_components[this.cid]) { + // ignore components that we aren't mapping + return; + } + _components[this.cid].renderCount = _components[this.cid].renderCount ? ++_components[this.cid].renderCount : 1; var performance = Array.prototype.slice.call(arguments, -1).pop(); var lastRenderTime = _components[this.cid].performance;