Skip to content

Commit 45d11f5

Browse files
author
Ives van Hoorne
committed
Add nullcheck
1 parent ff38564 commit 45d11f5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packages/app/src/sandbox/compile.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,10 @@ async function compile({
415415
try {
416416
const children = document.body.children;
417417
// Do unmounting for react
418-
if (manifest.dependencies.find(n => n.name === 'react-dom')) {
418+
if (
419+
manifest &&
420+
manifest.dependencies.find(n => n.name === 'react-dom')
421+
) {
419422
const reactDOMModule = manager.resolveModule('react-dom', '');
420423
const reactDOM = manager.evaluateModule(reactDOMModule);
421424

0 commit comments

Comments
 (0)