From 351eb34d6974cc881d6b2ea8b1bd139b8a4d984e Mon Sep 17 00:00:00 2001 From: Sebastian Markbage Date: Tue, 9 Aug 2016 12:34:31 -0700 Subject: [PATCH] Check for the explicit isTopLevelWrapper flag instead of flaky feature test I added this in https://github.com/facebook/react/pull/7164 --- backend/getData.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/backend/getData.js b/backend/getData.js index ef156e7c13..8495e63573 100644 --- a/backend/getData.js +++ b/backend/getData.js @@ -73,7 +73,10 @@ function getData(element: Object): DataType { name = element.getName(); // 0.14 top-level wrapper // TODO(jared): The backend should just act as if these don't exist. - if (element._renderedComponent && element._currentElement.props === element._renderedComponent._currentElement) { + if (element._renderedComponent && ( + element._currentElement.props === element._renderedComponent._currentElement || + element._currentElement.type.isReactTopLevelWrapper + )) { nodeType = 'Wrapper'; } if (name === null) {