@@ -5,9 +5,7 @@ import { Prompt } from 'react-router-dom';
55import { reaction } from 'mobx' ;
66import { TextOperation } from 'ot' ;
77import { inject , observer } from 'mobx-react' ;
8- import { uniqBy } from 'lodash-es' ;
98
10- import { getSandboxOptions } from '@codesandbox/common/lib/url' ;
119import getTemplateDefinition from '@codesandbox/common/lib/templates' ;
1210import type { ModuleError } from '@codesandbox/common/lib/types' ;
1311import { getPreviewTabs } from '@codesandbox/common/lib/templates/devtools' ;
@@ -470,28 +468,11 @@ class EditorPreview extends React.Component<Props, State> {
470468 }
471469 }
472470
473- const sandboxOptions = getSandboxOptions ( location . href ) ;
474- if (
475- ( sandboxOptions . previewWindow &&
476- sandboxOptions . previewWindow === 'tests' ) ||
477- sandboxOptions . previewWindow === 'console'
478- ) {
479- // Backwards compatibility for ?previewwindow=
480-
481- view = sandboxOptions . previewWindow ;
482- }
483-
484471 if ( view !== 'browser' ) {
485472 // Backwards compatibility for sandbox.config.json
486473 if ( view === 'console' ) {
487- views [ 0 ] . views = views [ 0 ] . views . filter (
488- t => t . id !== 'codesandbox.console'
489- ) ;
490474 views [ 0 ] . views . unshift ( { id : 'codesandbox.console' } ) ;
491475 } else if ( view === 'tests' ) {
492- views [ 0 ] . views = views [ 0 ] . views . filter (
493- t => t . id !== 'codesandbox.tests'
494- ) ;
495476 views [ 0 ] . views . unshift ( { id : 'codesandbox.tests' } ) ;
496477 }
497478 }
0 commit comments