Extract usage of require to separate function which can be tree-shaken by the monaco editor build and thus ignored by webpack

This commit is contained in:
Alex Dima
2022-11-09 09:39:20 +01:00
parent 5ad2852cc0
commit f46738bc47
17 changed files with 71 additions and 47 deletions

View File

@@ -1199,7 +1199,7 @@ export function asCSSUrl(uri: URI | null | undefined): string {
if (!uri) {
return `url('')`;
}
return `url('${FileAccess.asBrowserUri(uri).toString(true).replace(/'/g, '%27')}')`;
return `url('${FileAccess.uriToBrowserUri(uri).toString(true).replace(/'/g, '%27')}')`;
}
export function asCSSPropertyValue(value: string) {