diff --git a/src/runtime/injectStylesIntoStyleTag.js b/src/runtime/injectStylesIntoStyleTag.js index 0c8c0e59..068827f3 100644 --- a/src/runtime/injectStylesIntoStyleTag.js +++ b/src/runtime/injectStylesIntoStyleTag.js @@ -47,6 +47,10 @@ const getTarget = (function getTarget() { })(); function addModulesToDom(id, list, options) { + if (Object.prototype.toString.call(list) !== '[object Array]') { + return; + } + id = options.base ? id + options.base : id; if (!stylesInDom[id]) { diff --git a/test/runtime/__snapshots__/injectStylesIntoStyleTag.test.js.snap b/test/runtime/__snapshots__/injectStylesIntoStyleTag.test.js.snap index b42479cb..16927a92 100644 --- a/test/runtime/__snapshots__/injectStylesIntoStyleTag.test.js.snap +++ b/test/runtime/__snapshots__/injectStylesIntoStyleTag.test.js.snap @@ -1,5 +1,7 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP +exports[`addStyle issue 447 1`] = `"