lobalThis.MonacoEnvironment = { baseUrl: '${baseUrl}' };`,
				`globalThis._VSCODE_NLS_MESSAGES = ${JSON.stringify(nlsMessages)};`,
				`globalThis._VSCODE_NLS_LANGUAGE = ${JSON.stringify(nlsLanguage)};`,
				`globalThis._VSCODE_FILE_ROOT = '${fileRoot}';`,
				isESM ? `await import('${workerUrl}');` : `importScripts('${workerUrl}');`,
				isESM ? `globalThis.onmessage({ data: 'vs/workbench/api/worker/extensionHostWorker' });` : undefined, // important to start loading after the ESM async import has finishe