()
| 15 | import svgLoader from 'vite-svg-loader'; |
| 16 | |
| 17 | function patchCodeFilterOverflow(): Plugin { |
| 18 | return { |
| 19 | name: 'patch-code-filter-overflow', |
| 20 | configResolved(config) { |
| 21 | const target = config.plugins.find((p) => p.name === 'vite:asset-import-meta-url'); |
| 22 | if (target?.transform && typeof target.transform === 'object' && target.transform.filter) { |
| 23 | (target.transform.filter as Record<string, any>).code = 'import.meta.url'; |
| 24 | } |
| 25 | }, |
| 26 | }; |
| 27 | } |
| 28 | |
| 29 | const prefix = `monaco-editor/esm/vs`; |
| 30 |