From 37be0ab765fece085e3522e6ed261202966a936f Mon Sep 17 00:00:00 2001 From: Guillermo Rauch Date: Mon, 22 May 2017 12:58:54 -0700 Subject: [PATCH] filter for null *after* `Children` is called to make this work with some `-compat` pollyfills --- lib/head.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/head.js b/lib/head.js index 6200efe4..4f3b6a37 100644 --- a/lib/head.js +++ b/lib/head.js @@ -19,11 +19,11 @@ export function defaultHead () { function reduceComponents (components) { return components .map((c) => c.props.children) - .filter((c) => !!c) .map((children) => React.Children.toArray(children)) .reduce((a, b) => a.concat(b), []) .reverse() .concat(...defaultHead()) + .filter((c) => !!c) .filter(unique()) .reverse() .map((c) => {