diff --git a/src/playground/render-gui.jsx b/src/playground/render-gui.jsx index 6a2fc75e1..fe94f5bc7 100644 --- a/src/playground/render-gui.jsx +++ b/src/playground/render-gui.jsx @@ -1,21 +1,12 @@ import PropTypes from 'prop-types'; import React from 'react'; import {connect} from 'react-redux'; -import {compose} from 'redux'; import GUI from '../containers/gui.jsx'; -import TWParserHOC from '../lib/tw-parser-hoc.jsx'; -import AppStateHOC from '../lib/app-state-hoc.jsx'; const onClickLogo = () => { - // remove the hash to load the default project location.hash = ''; }; -if (process.env.NODE_ENV === 'production' && typeof window === 'object') { - // Warn before navigating away - window.onbeforeunload = () => true; -} - const searchParams = new URLSearchParams(location.search); const cloudHost = searchParams.get('cloud_host') || 'wss://clouddata.turbowarp.org'; diff --git a/src/playground/render-interface.jsx b/src/playground/render-interface.jsx index 73b869070..d8dfc58b0 100644 --- a/src/playground/render-interface.jsx +++ b/src/playground/render-interface.jsx @@ -16,15 +16,9 @@ import Examples from '../components/tw-examples/examples.jsx'; import styles from './gui.css'; const onClickLogo = () => { - // remove the hash to load the default project location.hash = ''; }; -if (process.env.NODE_ENV === 'production' && typeof window === 'object') { - // Warn before navigating away - window.onbeforeunload = () => true; -} - const Interface = ({isPlayerOnly}) => (
{isPlayerOnly ? ( @@ -70,9 +64,6 @@ const ConnectedInterface = connect( mapDispatchToProps )(Interface); -// note that redux's 'compose' function is just being used as a general utility to make -// the hierarchy of HOC constructor calls clearer here; it has nothing to do with redux's -// ability to compose reducers. const WrappedInterface = compose( AppStateHOC, TWParserHOC