diff --git a/packages/metal-incremental-dom/src/render/patch.js b/packages/metal-incremental-dom/src/render/patch.js index 3b948d11..942e1557 100644 --- a/packages/metal-incremental-dom/src/render/patch.js +++ b/packages/metal-incremental-dom/src/render/patch.js @@ -2,6 +2,7 @@ import { append, exitDocument } from 'metal-dom'; import { getData } from '../data'; +import { isServerSide } from 'metal'; import { render } from './render'; const patchingComponents_ = []; @@ -15,7 +16,10 @@ const patchingComponents_ = []; */ function buildParentIfNecessary_(element) { if (!element || !element.parentNode) { - const parent = document.createElement('div'); + let parent = {}; + if (!isServerSide()) { + parent = document.createElement('div'); + } if (element) { append(parent, element); }