blob: 5696ddb57d8f46e5541e6c60f10e07f216e1b312 [file] [log] [blame]
Adrià Vilanova Martínez2ba5d8d2024-05-04 21:17:16 +02001import Script, { ConcreteScript } from '../common/architecture/scripts/Script';
2import ScriptFilterListProvider from '../common/architecture/scripts/ScriptFilterListProvider';
Adrià Vilanova Martínezc78c3ad2024-05-18 00:35:51 +02003import InjectLitComponentsScript from './litComponents/injectLitComponents.script';
Adrià Vilanova Martínez2ba5d8d2024-05-04 21:17:16 +02004import MWI18nServerScript from './mainWorldServers/MWI18nServerScript.script';
5import MWOptionsWatcherServerScript from './mainWorldServers/MWOptionsWatcherServerScript.script';
Adrià Vilanova Martínezf7e86852024-05-11 14:16:38 +02006import OptionsProviderSetUpScript from './optionsProvider/optionsProvider.script';
Adrià Vilanova Martínez2ba5d8d2024-05-04 21:17:16 +02007import XHRInterceptorScript from './xhrInterceptor/xhrInterceptor.script';
8
9export default class StandaloneScripts extends ScriptFilterListProvider {
10 private scripts: ConcreteScript[] = [
Adrià Vilanova Martínezc78c3ad2024-05-18 00:35:51 +020011 InjectLitComponentsScript,
Adrià Vilanova Martínez2ba5d8d2024-05-04 21:17:16 +020012 MWI18nServerScript,
13 MWOptionsWatcherServerScript,
Adrià Vilanova Martínezf7e86852024-05-11 14:16:38 +020014 OptionsProviderSetUpScript,
Adrià Vilanova Martínez2ba5d8d2024-05-04 21:17:16 +020015 XHRInterceptorScript,
16 ];
17 private initializedScripts: Script[];
18
19 protected getUnfilteredScriptsList() {
20 if (this.initializedScripts === undefined) {
21 this.initializedScripts = this.scripts.map((script) => new script());
22 }
23 return this.initializedScripts;
24 }
25}