File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -185,6 +185,7 @@ export interface LoaderOptions {
185185 * ```
186186 */
187187export class Loader {
188+ private static instance : Loader ;
188189 /**
189190 * See [[LoaderOptions.version]]
190191 */
@@ -244,7 +245,6 @@ export class Loader {
244245 private done = false ;
245246 private loading = false ;
246247 private onerrorEvent : ErrorEvent ;
247- private static instance : Loader ;
248248 private errors : ErrorEvent [ ] = [ ] ;
249249
250250 /**
@@ -363,6 +363,13 @@ export class Loader {
363363 return url ;
364364 }
365365
366+ public deleteScript ( ) : void {
367+ const script = document . getElementById ( this . id ) ;
368+ if ( script ) {
369+ script . remove ( ) ;
370+ }
371+ }
372+
366373 /**
367374 * Load the Google Maps JavaScript API script and return a Promise.
368375 */
@@ -421,13 +428,6 @@ export class Loader {
421428 document . head . appendChild ( script ) ;
422429 }
423430
424- public deleteScript ( ) : void {
425- const script = document . getElementById ( this . id ) ;
426- if ( script ) {
427- script . remove ( ) ;
428- }
429- }
430-
431431 /**
432432 * Reset the loader state.
433433 */
You can’t perform that action at this time.
0 commit comments