static updateEditorSpace(e) {
        if(HashBrown.Context.currentResourceEditor && HashBrown.Context.currentResourceEditor.isDirty) {
            e.preventDefault();

            UI.highlight(false);

            UI.confirm(
                'Discard unsaved changes?',
                'You have unsaved changes. Do you want to discard them?',
                () => {
                    HashBrown.Context.currentResourceEditor = null;
                    this.poke();
                },
                () => {
                    this.skipRoute = true;
                    location = e.oldURL;
                }
            );

            return;
        }

        HashBrown.Context.currentResourceEditor = null;
        
        let category = this.getRoute(0);
        let resourceId = this.getRoute(1);
        let isJson = this.getRoute(2) === 'json';

        let space = document.querySelector('.page--environment__space--editor');

        space.innerHTML = '';

        let editor = null;

        if(isJson) {
            editor = new HashBrown.Entity.View.ResourceEditor.JsonEditor();

        } else {
            for(let name in HashBrown.Entity.View.ResourceEditor) {
                let type = HashBrown.Entity.View.ResourceEditor[name];

                if(type === HashBrown.Entity.View.ResourceEditor.JsonEditor) { continue; }
                if(type.category !== category) { continue; }

                editor = new type();
                break;
            }
            
            if(!editor) {
                for(let name in HashBrown.View.Editor) {
                    let type = HashBrown.View.Editor[name];

                    if(type.prototype instanceof HashBrown.View.Editor.ResourceEditor === false) { continue; }
                    if(type.category !== category) { continue; }

                    editor = new type();
                    break;
                }
            }
        }

        if(!editor) {
            space.innerHTML = `No resource editor for category "${category}" was found`;
            return;
        }

        HashBrown.Context.currentResourceEditor = editor;

        space.appendChild(
            editor.element
        );
    }
/**
     * Updates the editor space with the appropriate welcome screen or resource editor
     *
     * @param {HashChangeEvent} e
     */
Updates the editor space with the appropriate welcome screen or resource editor
@param {HashChangeEvent} e
Updates the editor space with the appropriate welcome screen or resource editor @param { HashChangeEvent } e
static updateEditorSpace(e) {
        if(HashBrown.Context.currentResourceEditor && HashBrown.Context.currentResourceEditor.isDirty) {
            e.preventDefault();
            UI.highlight(false);
            UI.confirm(
                'Discard unsaved changes?',
                'You have unsaved changes. Do you want to discard them?',
                () => {
                    HashBrown.Context.currentResourceEditor = null;
                    this.poke();
                },
                () => {
                    this.skipRoute = true;
                    location = e.oldURL;
                }
            );
            return;
        }
        HashBrown.Context.currentResourceEditor = null;
        let category = this.getRoute(0);
        let resourceId = this.getRoute(1);
        let isJson = this.getRoute(2) === 'json';
        let space = document.querySelector('.page--environment__space--editor');
        space.innerHTML = '';
        let editor = null;
        if(isJson) {
            editor = new HashBrown.Entity.View.ResourceEditor.JsonEditor();
        } else {
            for(let name in HashBrown.Entity.View.ResourceEditor) {
                let type = HashBrown.Entity.View.ResourceEditor[name];
                if(type === HashBrown.Entity.View.ResourceEditor.JsonEditor) { continue; }
                if(type.category !== category) { continue; }
                editor = new type();
                break;
            }
            if(!editor) {
                for(let name in HashBrown.View.Editor) {
                    let type = HashBrown.View.Editor[name];
                    if(type.prototype instanceof HashBrown.View.Editor.ResourceEditor === false) { continue; }
                    if(type.category !== category) { continue; }
                    editor = new type();
                    break;
                }
            }
        }
        if(!editor) {
            space.innerHTML = `No resource editor for category "${category}" was found`;
            return;
        }
        HashBrown.Context.currentResourceEditor = editor;
        space.appendChild(
            editor.element
        );
    }
static updateEditorSpace ( e ) { if ( HashBrown . Context . currentResourceEditor && HashBrown . Context . currentResourceEditor . isDirty ) { e . preventDefault ( ) ; UI . highlight ( false ) ; UI . confirm ( 'Discard unsaved changes?' , 'You have unsaved changes. Do you want to discard them?' , ( ) => { HashBrown . Context . currentResourceEditor = null ; this . poke ( ) ; } , ( ) => { this . skipRoute = true ; location = e . oldURL ; } ) ; return ; } HashBrown . Context . currentResourceEditor = null ; let category = this . getRoute ( 0 ) ; let resourceId = this . getRoute ( 1 ) ; let isJson = this . getRoute ( 2 ) === 'json' ; let space = document . querySelector ( '.page--environment__space--editor' ) ; space . innerHTML = '' ; let editor = null ; if ( isJson ) { editor = new HashBrown . Entity . View . ResourceEditor . JsonEditor ( ) ; } else { for ( let name in HashBrown . Entity . View . ResourceEditor ) { let type = HashBrown . Entity . View . ResourceEditor [ name ] ; if ( type === HashBrown . Entity . View . ResourceEditor . JsonEditor ) { continue ; } if ( type . category !== category ) { continue ; } editor = new type ( ) ; break ; } if ( ! editor ) { for ( let name in HashBrown . View . Editor ) { let type = HashBrown . View . Editor [ name ] ; if ( type . prototype instanceof HashBrown . View . Editor . ResourceEditor === false ) { continue ; } if ( type . category !== category ) { continue ; } editor = new type ( ) ; break ; } } } if ( ! editor ) { space . innerHTML = ` ${ category } ` ; return ; } HashBrown . Context . currentResourceEditor = editor ; space . appendChild ( editor . element ) ; }
Updates the editor space with the appropriate welcome screen or resource editor
 @param {HashChangeEvent} e
Updates the editor space with the appropriate welcome screen or resource editor @param { HashChangeEvent } e