diff --git a/client/modules/IDE/components/PreviewFrame.jsx b/client/modules/IDE/components/PreviewFrame.jsx index 507bdfb7..eb23b94e 100644 --- a/client/modules/IDE/components/PreviewFrame.jsx +++ b/client/modules/IDE/components/PreviewFrame.jsx @@ -31,6 +31,12 @@ class PreviewFrame extends React.Component { } componentDidUpdate(prevProps) { + // if sketch starts or stops playing, want to rerender + if (this.props.isPlaying !== prevProps.isPlaying) { + this.renderSketch(); + return; + } + // if the user explicitly clicks on the play button if (this.props.isPlaying && this.props.previewIsRefreshing) { this.renderSketch();