feat(editor): improve TypeScript IntelliSense and module resolution for Monaco editor

This commit is contained in:
2025-12-30 17:08:28 +00:00
parent 0b06499664
commit a823e8aaa6
4 changed files with 86 additions and 7 deletions

View File

@@ -1,5 +1,15 @@
# Changelog
## 2025-12-30 - 3.16.0 - feat(editor)
improve TypeScript IntelliSense and module resolution for Monaco editor
- Add file cache (fileCache) and getFileContent() for synchronous access to project files
- Track and dispose Monaco extra libs (addedExtraLibs) and register project files via addExtraLib to enable TypeScript module resolution
- Add addFileAsExtraLib logic to register .ts/.tsx files also under .js/.jsx paths so ESM imports resolve to TypeScript sources
- Use ModuleResolutionKind.Bundler fallback to NodeJs and set compilerOptions (baseUrl '/', allowImportingTsExtensions, resolveJsonModule) to improve resolution
- Adapt executionEnvironment API usage to readDir/readFile and check entry.type ('directory'|'file') instead of isDirectory/isFile
- Add a debugging/screenshot asset: .playwright-mcp/module-resolution-fixed.png
## 2025-12-30 - 3.15.0 - feat(editor)
enable file-backed Monaco models and add Problems panel; lazy-init project TypeScript IntelliSense