We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ec557ed commit 56f5127Copy full SHA for 56f5127
editor/index.html
@@ -193,6 +193,8 @@
193
194
editor.storage.get( function ( state ) {
195
196
+ if ( isLoadingFromHash ) return;
197
+
198
if ( state !== undefined ) {
199
200
editor.fromJSON( state );
@@ -324,6 +326,7 @@
324
326
325
327
//
328
329
+ var isLoadingFromHash = false;
330
var hash = window.location.hash;
331
332
if ( hash.substr( 1, 5 ) === 'file=' ) {
@@ -336,13 +339,13 @@
336
339
loader.crossOrigin = '';
337
340
loader.load( file, function ( text ) {
338
341
- var json = JSON.parse( text );
-
342
editor.clear();
- editor.fromJSON( json );
343
+ editor.fromJSON( JSON.parse( text ) );
344
345
} );
346
347
+ isLoadingFromHash = true;
348
349
}
350
351
0 commit comments