Skip to content

Upgrade monaco-editor to 0.55.1 and fix breaking API changes - #251

Merged
Blankll merged 2 commits into
snyk-upgrade-99337c67ef9366dbe6f59026e3b5c1a6from
copilot/sub-pr-240
Dec 26, 2025
Merged

Blankll merged 2 commits into
snyk-upgrade-99337c67ef9366dbe6f59026e3b5c1a6from
copilot/sub-pr-240

Conversation

Copilot AI commented Dec 26, 2025 •

Copy link
Copy Markdown
Contributor

Monaco-editor 0.55.0 introduced breaking changes by moving nested namespaces (languages.typescript, languages.json, etc.) to top-level exports. The existing code used the deprecated API, causing TypeScript compilation failures.

Changes

  • Updated monaco-editor: 0.53.0 → 0.55.1 (latest stable)
  • Fixed TypeScript namespace usage: Migrated from monaco.languages.typescript.typescriptDefaults to top-level typescript.typescriptDefaults export
  • Added Window type extension: Declared MonacoEnvironment property on Window interface to resolve TypeScript compilation error
  • Updated test mocks: Reflected new API structure in Jest mocks

Example

// Before (deprecated in 0.55.0)
import * as monaco from 'monaco-editor';
monaco.languages.typescript.typescriptDefaults.setEagerModelSync(true);

// After
import * as monaco from 'monaco-editor';
import { typescript } from 'monaco-editor';
typescript.typescriptDefaults.setEagerModelSync(true);

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

- Add Window.MonacoEnvironment type declaration to fix TypeScript error
- Update to monaco-editor 0.55.1 (latest version)
- Fix typescript namespace usage (moved from monaco.languages.typescript to top-level typescript export)
- Update test mocks to match new monaco-editor API structure

Co-authored-by: Blankll <28639911+Blankll@users.noreply.github.com>
Copilot AI changed the title [WIP] Upgrade monaco-editor from 0.52.2 to 0.53.0 Upgrade monaco-editor to 0.55.1 and fix breaking API changes Dec 26, 2025
Copilot AI requested a review from Blankll December 26, 2025 08:11
@Blankll
Blankll marked this pull request as ready for review December 26, 2025 08:32
@Blankll
Blankll merged commit aeb59ee into snyk-upgrade-99337c67ef9366dbe6f59026e3b5c1a6 Dec 26, 2025
1 check passed
@Blankll
Blankll deleted the copilot/sub-pr-240 branch December 26, 2025 08:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants