Skip to content

Commit 607394e

Browse files
authored
Merge pull request #829 from TypeFox/issue-827
View service related imports are made dynamically
2 parents a97aeed + 22ec79c commit 607394e

34 files changed

+365
-913
lines changed

docs/CHANGELOG.md

Lines changed: 0 additions & 602 deletions
This file was deleted.

docs/versions-and-history.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ The following table describes which version of **monaco-languageclient** and **@
66

77
| monaco-languageclient | monaco-editor-wrapper | monaco-editor-react | monaco-vscode-api / editor-api | vscode | monaco-editor | release date | comment |
88
| :---- | :---- | :--- | :--- | :--- | :--- | :--- | :--- |
9+
| 9.1.1 | 6.1.1 | 6.1.1 | 11.1.2 | 1.95.3 | 0.52.0 | 2025-01-20 | |
910
| 9.1.0 | 6.1.0 | 6.1.0 | 11.1.2 | 1.95.3 | 0.52.0 | 2025-01-10 | |
1011
| 9.0.0 | 6.0.0 | 6.0.0 | 11.1.2 | 1.95.3 | 0.52.0 | 2024-12-18 | |
1112
| 8.8.3 | 5.5.3 | 4.5.3 | 8.0.4 | 1.92.2 | 0.51.0 | 2024-08-26 | |

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ <h3>JSON</h3>
3434

3535
<h3>Langium</h3>
3636

37-
<a href="./packages/examples/langium.html">Langium Grammar DSL Language Client & Language Server (Worker)</a>
37+
Langium Grammar DSL: <a href="./packages/examples/langium_extended.html">Extended Mode</a> - <a href="./packages/examples/langium_classic.html">Classic Mode</a>
3838
<br>
3939
<a href="./packages/examples/statemachine.html">Langium Statemachine Client & Language Server (Worker)</a>
4040
<br>

package-lock.json

Lines changed: 184 additions & 183 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 14 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -15,20 +15,20 @@
1515
"@codingame/esbuild-import-meta-url-plugin": "~1.0.2",
1616
"@codingame/monaco-vscode-rollup-vsix-plugin": "~11.1.2",
1717
"@eslint/eslintrc": "~3.2.0",
18-
"@eslint/js": "~9.17.0",
19-
"@stylistic/eslint-plugin": "~2.12.1",
20-
"@testing-library/react": "~16.1.0",
21-
"@types/node": "~22.10.5",
22-
"@types/react": "~19.0.4",
23-
"@types/react-dom": "~19.0.2",
18+
"@eslint/js": "~9.18.0",
19+
"@stylistic/eslint-plugin": "~2.13.0",
20+
"@testing-library/react": "~16.2.0",
21+
"@types/node": "~22.10.7",
22+
"@types/react": "~19.0.7",
23+
"@types/react-dom": "~19.0.3",
2424
"@types/vscode": "~1.95.0",
25-
"@typescript-eslint/eslint-plugin": "~8.19.1",
26-
"@typescript-eslint/parser": "~8.19.1",
25+
"@typescript-eslint/eslint-plugin": "~8.20.0",
26+
"@typescript-eslint/parser": "~8.20.0",
2727
"@vitejs/plugin-react": "~4.3.4",
28-
"@vitest/browser": "~2.1.8",
28+
"@vitest/browser": "~3.0.2",
2929
"editorconfig": "~2.0.0",
3030
"esbuild": "~0.24.2",
31-
"eslint": "~9.17.0",
31+
"eslint": "~9.18.0",
3232
"eslint-plugin-header": "~3.1.1",
3333
"eslint-plugin-import": "~2.31.0",
3434
"eslint-plugin-unused-imports": "~4.1.4",
@@ -37,9 +37,9 @@
3737
"minimatch": "~10.0.1",
3838
"playwright": "~1.49.1",
3939
"typescript": "~5.7.3",
40-
"vite": "~6.0.7",
41-
"vite-node": "~2.1.8",
42-
"vitest": "~2.1.8"
40+
"vite": "~6.0.8",
41+
"vite-node": "~3.0.2",
42+
"vitest": "~3.0.2"
4343
},
4444
"scripts": {
4545
"clean": "npm run clean --workspaces",
@@ -77,8 +77,5 @@
7777
"packages/wrapper",
7878
"packages/wrapper-react",
7979
"packages/examples"
80-
],
81-
"overrides": {
82-
"vite": "~6.0.7"
83-
}
80+
]
8481
}

packages/client/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
All notable changes to this npm module are documented in this file.
44

5+
## [9.1.1] - 2025-01-20
6+
7+
- View service related imports are made dynamically [#829](https://github.com/TypeFox/monaco-languageclient/pull/829)
8+
59
## [9.1.0] - 2025-01-10
610

711
- `@typefox/monaco-editor-react` now works with views service `initialize` [#823](https://github.com/TypeFox/monaco-languageclient/pull/823)

packages/client/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "monaco-languageclient",
3-
"version": "9.1.0",
3+
"version": "9.1.1",
44
"description": "Monaco Language client implementation",
55
"author": {
66
"name": "TypeFox GmbH",

packages/client/src/vscode/services.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import * as monaco from 'monaco-editor';
77
import 'vscode/localExtensionHost';
88
import { initialize, IWorkbenchConstructionOptions } from 'vscode/services';
9-
import { OpenEditor } from '@codingame/monaco-vscode-editor-service-override';
9+
import type { OpenEditor } from '@codingame/monaco-vscode-editor-service-override';
1010
import type { WorkerConfig } from '@codingame/monaco-vscode-extensions-service-override';
1111
import getExtensionServiceOverride from '@codingame/monaco-vscode-extensions-service-override';
1212
import getLanguagesServiceOverride from '@codingame/monaco-vscode-languages-service-override';
@@ -31,7 +31,7 @@ export interface ViewsConfig {
3131
viewServiceType: 'EditorService' | 'ViewsService' | 'WorkspaceService';
3232
openEditorFunc?: OpenEditor;
3333
htmlAugmentationInstructions?: (htmlContainer: HTMLElement | null | undefined) => void;
34-
viewsInitFunc?: () => void;
34+
viewsInitFunc?: () => Promise<void>;
3535
}
3636

3737
export interface VscodeApiConfig {
@@ -112,7 +112,7 @@ export const initServices = async (vscodeApiConfig: VscodeApiConfig, instruction
112112
await importAllServices(vscodeApiConfig, instructions);
113113

114114
vscodeApiConfig.viewsConfig?.htmlAugmentationInstructions?.(instructions?.htmlContainer);
115-
vscodeApiConfig.viewsConfig?.viewsInitFunc?.();
115+
await vscodeApiConfig.viewsConfig?.viewsInitFunc?.();
116116
instructions?.logger?.debug('Initialization of vscode services completed successfully.');
117117

118118
envEnhanced.vscodeApiInitialised = true;

packages/examples/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22

33
All notable changes to this npm module are documented in this file.
44

5+
## [2025.1.2] - 2025-01-20
6+
7+
- Updated to `monaco-languageclient@9.1.1`, `monaco-editor-wrapper@6.1.1` and `@typefox/monaco-editor-react@6.1.1`.
8+
- View service related imports are made dynamically [#829](https://github.com/TypeFox/monaco-languageclient/pull/829)
9+
- Separated Langium DSL example into Extended and Classic Mode versions
10+
511
## [2025.1.1] - 2025-01-10
612

713
- Updated to `monaco-languageclient@9.1.0`, `monaco-editor-wrapper@6.1.0` and `@typefox/monaco-editor-react@6.1.0`.

packages/examples/ghp_langium.html renamed to packages/examples/ghp_langium_classic.html

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,25 +2,24 @@
22
<html lang="en">
33

44
<head>
5-
<title>Langium Grammar DSL Language Client & Language Server (Worker)</title>
5+
<title>Langium Grammar DSL (Classic Mode)</title>
66
<meta charset="UTF-8" />
77
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
88
<link rel="stylesheet" href="style.css">
99
</head>
1010

1111
<body>
1212
<div class="exampleHeadelineDiv">
13-
<b class="exampleHeadeline">Langium Grammar DSL Language Client & Language Server (Worker)</b> - [<a href="./index.html">Back to Index</a>]
13+
<b class="exampleHeadeline">Langium Grammar DSL (Classic Mode)</b> - [<a href="./index.html">Back to Index</a>]
1414
<br>
15-
<button type="button" id="button-start-classic">Start Classic</button>
16-
<button type="button" id="button-start-extended">Start Extended</button>
15+
<button type="button" id="button-start">Start</button>
1716
<button type="button" id="button-dispose">Dispose</button>
1817
</div>
1918
<div id="monaco-editor-root" style="height: 80vh; border: 1px solid grey"></div>
2019
<script type="module">
2120
import { runLangiumDslWrapper } from './src/langium/langium-dsl/wrapperLangium.ts';
2221

23-
runLangiumDslWrapper();
22+
runLangiumDslWrapper(false);
2423
</script>;
2524
</body>
2625

0 commit comments

Comments
 (0)