Skip to content

Commit cf42252

Browse files
author
Ives van Hoorne
committed
Only update deps when editing code
1 parent 65c9f0b commit cf42252

File tree

1 file changed

+4
-1
lines changed
  • src/app/pages/Sandbox/Editor/Content/subviews/Preview

1 file changed

+4
-1
lines changed

src/app/pages/Sandbox/Editor/Content/subviews/Preview/index.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,10 @@ export default class Preview extends React.PureComponent {
112112
prevProps.directories !== this.props.directories) &&
113113
this.state.frameInitialized
114114
) {
115-
if (this.props.preferences.livePreviewEnabled) {
115+
if (
116+
this.props.preferences.livePreviewEnabled &&
117+
prevProps.bundle === this.props.bundle
118+
) {
116119
this.executeCode();
117120
}
118121
}

0 commit comments

Comments
 (0)