monaco-languageclient-examples 6.4.5-next.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (92) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/License.txt +11 -0
  3. package/README.md +17 -0
  4. package/browser.html +16 -0
  5. package/client.html +16 -0
  6. package/dist/browser/main.d.ts +2 -0
  7. package/dist/browser/main.d.ts.map +1 -0
  8. package/dist/browser/main.js +111 -0
  9. package/dist/browser/main.js.map +1 -0
  10. package/dist/common.d.ts +22 -0
  11. package/dist/common.d.ts.map +1 -0
  12. package/dist/common.js +109 -0
  13. package/dist/common.js.map +1 -0
  14. package/dist/index.d.ts +9 -0
  15. package/dist/index.d.ts.map +1 -0
  16. package/dist/index.js +13 -0
  17. package/dist/index.js.map +1 -0
  18. package/dist/json/client/main.d.ts +2 -0
  19. package/dist/json/client/main.d.ts.map +1 -0
  20. package/dist/json/client/main.js +19 -0
  21. package/dist/json/client/main.js.map +1 -0
  22. package/dist/json/server/json-server.d.ts +36 -0
  23. package/dist/json/server/json-server.d.ts.map +1 -0
  24. package/dist/json/server/json-server.js +216 -0
  25. package/dist/json/server/json-server.js.map +1 -0
  26. package/dist/json/server/main.d.ts +2 -0
  27. package/dist/json/server/main.d.ts.map +1 -0
  28. package/dist/json/server/main.js +64 -0
  29. package/dist/json/server/main.js.map +1 -0
  30. package/dist/langium/langiumClient.d.ts +2 -0
  31. package/dist/langium/langiumClient.d.ts.map +1 -0
  32. package/dist/langium/langiumClient.js +130 -0
  33. package/dist/langium/langiumClient.js.map +1 -0
  34. package/dist/langium/langiumServerWorker.d.ts +2 -0
  35. package/dist/langium/langiumServerWorker.d.ts.map +1 -0
  36. package/dist/langium/langiumServerWorker.js +18 -0
  37. package/dist/langium/langiumServerWorker.js.map +1 -0
  38. package/dist/langium/statemachineClient.d.ts +2 -0
  39. package/dist/langium/statemachineClient.d.ts.map +1 -0
  40. package/dist/langium/statemachineClient.js +140 -0
  41. package/dist/langium/statemachineClient.js.map +1 -0
  42. package/dist/node.d.ts +5 -0
  43. package/dist/node.d.ts.map +1 -0
  44. package/dist/node.js +9 -0
  45. package/dist/node.js.map +1 -0
  46. package/dist/python/client.d.ts +3 -0
  47. package/dist/python/client.d.ts.map +1 -0
  48. package/dist/python/client.js +157 -0
  49. package/dist/python/client.js.map +1 -0
  50. package/dist/python/server.d.ts +2 -0
  51. package/dist/python/server.d.ts.map +1 -0
  52. package/dist/python/server.js +105 -0
  53. package/dist/python/server.js.map +1 -0
  54. package/dist/react/app.d.ts +10 -0
  55. package/dist/react/app.d.ts.map +1 -0
  56. package/dist/react/app.js +45 -0
  57. package/dist/react/app.js.map +1 -0
  58. package/dist/react/main.d.ts +2 -0
  59. package/dist/react/main.d.ts.map +1 -0
  60. package/dist/react/main.js +14 -0
  61. package/dist/react/main.js.map +1 -0
  62. package/dist/utils/fs-utils.d.ts +5 -0
  63. package/dist/utils/fs-utils.d.ts.map +1 -0
  64. package/dist/utils/fs-utils.js +14 -0
  65. package/dist/utils/fs-utils.js.map +1 -0
  66. package/dist/worker/langiumServerWorker.js +210 -0
  67. package/dist/worker/statemachineServerWorker.js +534 -0
  68. package/langium_client.html +17 -0
  69. package/package.json +96 -0
  70. package/python.html +16 -0
  71. package/react.html +16 -0
  72. package/src/browser/main.ts +131 -0
  73. package/src/common.ts +130 -0
  74. package/src/index.ts +13 -0
  75. package/src/json/client/main.ts +22 -0
  76. package/src/json/server/json-server.ts +265 -0
  77. package/src/json/server/main.ts +68 -0
  78. package/src/langium/example.langium +215 -0
  79. package/src/langium/example.statemachine +26 -0
  80. package/src/langium/langium.configuration.json +164 -0
  81. package/src/langium/langium.tmLanguage.json +290 -0
  82. package/src/langium/langiumClient.ts +146 -0
  83. package/src/langium/langiumServerWorker.ts +21 -0
  84. package/src/langium/statemachineClient.ts +151 -0
  85. package/src/node.ts +9 -0
  86. package/src/python/client.ts +170 -0
  87. package/src/python/server.ts +114 -0
  88. package/src/react/app.tsx +73 -0
  89. package/src/react/main.tsx +19 -0
  90. package/src/utils/fs-utils.ts +14 -0
  91. package/statemachine_client.html +16 -0
  92. package/vite.statemachine-worker.ts +17 -0
package/dist/node.d.ts ADDED
@@ -0,0 +1,5 @@
1
+ export * from './json/server/json-server.js';
2
+ export * from './json/server/main.js';
3
+ export * from './python/server.js';
4
+ export * from './utils/fs-utils.js';
5
+ //# sourceMappingURL=node.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"node.d.ts","sourceRoot":"","sources":["../src/node.ts"],"names":[],"mappings":"AAKA,cAAc,8BAA8B,CAAC;AAC7C,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,cAAc,qBAAqB,CAAC"}
package/dist/node.js ADDED
@@ -0,0 +1,9 @@
1
+ /* --------------------------------------------------------------------------------------------
2
+ * Copyright (c) 2018-2022 TypeFox GmbH (http://www.typefox.io). All rights reserved.
3
+ * Licensed under the MIT License. See License.txt in the project root for license information.
4
+ * ------------------------------------------------------------------------------------------ */
5
+ export * from './json/server/json-server.js';
6
+ export * from './json/server/main.js';
7
+ export * from './python/server.js';
8
+ export * from './utils/fs-utils.js';
9
+ //# sourceMappingURL=node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"node.js","sourceRoot":"","sources":["../src/node.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAEhG,cAAc,8BAA8B,CAAC;AAC7C,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,cAAc,qBAAqB,CAAC"}
@@ -0,0 +1,3 @@
1
+ import 'vscode/default-extensions/theme-defaults';
2
+ import 'vscode/default-extensions/python';
3
+ //# sourceMappingURL=client.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../src/python/client.ts"],"names":[],"mappings":"AAOA,OAAO,0CAA0C,CAAC;AAClD,OAAO,kCAAkC,CAAC"}
@@ -0,0 +1,157 @@
1
+ /* --------------------------------------------------------------------------------------------
2
+ * Copyright (c) 2018-2022 TypeFox GmbH (http://www.typefox.io). All rights reserved.
3
+ * Licensed under the MIT License. See License.txt in the project root for license information.
4
+ * ------------------------------------------------------------------------------------------ */
5
+ import * as monaco from 'monaco-editor';
6
+ import * as vscode from 'vscode';
7
+ import 'vscode/default-extensions/theme-defaults';
8
+ import 'vscode/default-extensions/python';
9
+ import { updateUserConfiguration } from 'vscode/service-override/configuration';
10
+ import { LogLevel } from 'vscode/services';
11
+ import { createConfiguredEditor, createModelReference } from 'vscode/monaco';
12
+ import { registerExtension } from 'vscode/extensions';
13
+ import { initServices, MonacoLanguageClient } from 'monaco-languageclient';
14
+ import { CloseAction, ErrorAction } from 'vscode-languageclient';
15
+ import { WebSocketMessageReader, WebSocketMessageWriter, toSocket } from 'vscode-ws-jsonrpc';
16
+ import { RegisteredFileSystemProvider, registerFileSystemOverlay, RegisteredMemoryFile } from 'vscode/service-override/files';
17
+ import { buildWorkerDefinition } from 'monaco-editor-workers';
18
+ import { createUrl } from '../common.js';
19
+ buildWorkerDefinition('../../../node_modules/monaco-editor-workers/dist/workers/', new URL('', window.location.href).href, false);
20
+ const languageId = 'python';
21
+ let languageClient;
22
+ const createWebSocket = (url) => {
23
+ const webSocket = new WebSocket(url);
24
+ webSocket.onopen = async () => {
25
+ const socket = toSocket(webSocket);
26
+ const reader = new WebSocketMessageReader(socket);
27
+ const writer = new WebSocketMessageWriter(socket);
28
+ languageClient = createLanguageClient({
29
+ reader,
30
+ writer
31
+ });
32
+ await languageClient.start();
33
+ reader.onClose(() => languageClient.stop());
34
+ };
35
+ return webSocket;
36
+ };
37
+ const createLanguageClient = (transports) => {
38
+ return new MonacoLanguageClient({
39
+ name: 'Pyright Language Client',
40
+ clientOptions: {
41
+ // use a language id as a document selector
42
+ documentSelector: [languageId],
43
+ // disable the default error handler
44
+ errorHandler: {
45
+ error: () => ({ action: ErrorAction.Continue }),
46
+ closed: () => ({ action: CloseAction.DoNotRestart })
47
+ },
48
+ // pyright requires a workspace folder to be present, otherwise it will not work
49
+ workspaceFolder: {
50
+ index: 0,
51
+ name: 'workspace',
52
+ uri: monaco.Uri.parse('/tmp')
53
+ },
54
+ synchronize: {
55
+ fileEvents: [vscode.workspace.createFileSystemWatcher('**')]
56
+ }
57
+ },
58
+ // create a language client connection from the JSON RPC connection on demand
59
+ connectionProvider: {
60
+ get: () => {
61
+ return Promise.resolve(transports);
62
+ }
63
+ }
64
+ });
65
+ };
66
+ const run = async () => {
67
+ // init vscode-api
68
+ await initServices({
69
+ enableModelService: true,
70
+ enableThemeService: true,
71
+ enableTextmateService: true,
72
+ configureConfigurationService: {
73
+ defaultWorkspaceUri: '/tmp'
74
+ },
75
+ enableLanguagesService: true,
76
+ enableKeybindingsService: true,
77
+ debugLogging: true,
78
+ logLevel: LogLevel.Debug
79
+ });
80
+ // extension configuration derived from:
81
+ // https://github.com/microsoft/pyright/blob/main/packages/vscode-pyright/package.json
82
+ // only a minimum is required to get pyright working
83
+ const extension = {
84
+ name: 'python-client',
85
+ publisher: 'monaco-languageclient-project',
86
+ version: '1.0.0',
87
+ engines: {
88
+ vscode: '^1.78.0'
89
+ },
90
+ contributes: {
91
+ languages: [{
92
+ id: languageId,
93
+ aliases: [
94
+ 'Python'
95
+ ],
96
+ extensions: [
97
+ '.py',
98
+ '.pyi'
99
+ ]
100
+ }],
101
+ commands: [{
102
+ command: 'pyright.restartserver',
103
+ title: 'Pyright: Restart Server',
104
+ category: 'Pyright'
105
+ },
106
+ {
107
+ command: 'pyright.organizeimports',
108
+ title: 'Pyright: Organize Imports',
109
+ category: 'Pyright'
110
+ }],
111
+ keybindings: [{
112
+ key: 'ctrl+k',
113
+ command: 'pyright.restartserver',
114
+ when: 'editorTextFocus'
115
+ }]
116
+ }
117
+ };
118
+ registerExtension(extension, 1 /* ExtensionHostKind.LocalProcess */);
119
+ updateUserConfiguration(`{
120
+ "editor.fontSize": 14,
121
+ "workbench.colorTheme": "Default Dark Modern"
122
+ }`);
123
+ const fileSystemProvider = new RegisteredFileSystemProvider(false);
124
+ fileSystemProvider.registerFile(new RegisteredMemoryFile(vscode.Uri.file('/tmp/hello.py'), 'print("Hello, World!")'));
125
+ registerFileSystemOverlay(1, fileSystemProvider);
126
+ // create the web socket and configure to start the language client on open, can add extra parameters to the url if needed.
127
+ createWebSocket(createUrl('localhost', 30000, '/pyright', {
128
+ // Used to parse an auth token or additional parameters such as import IDs to the language server
129
+ authorization: 'UserAuth'
130
+ // By commenting above line out and commenting below line in, connection to language server will be denied.
131
+ // authorization: 'FailedUserAuth'
132
+ }, false));
133
+ const registerCommand = async (cmdName, handler) => {
134
+ // commands sould not be there, but it demonstrates how to retrieve list of all external commands
135
+ const commands = await vscode.commands.getCommands(true);
136
+ if (!commands.includes(cmdName)) {
137
+ vscode.commands.registerCommand(cmdName, handler);
138
+ }
139
+ };
140
+ // always exectute the command with current language client
141
+ await registerCommand('pyright.restartserver', (...args) => {
142
+ languageClient.sendRequest('workspace/executeCommand', { command: 'pyright.restartserver', arguments: args });
143
+ });
144
+ await registerCommand('pyright.organizeimports', (...args) => {
145
+ languageClient.sendRequest('workspace/executeCommand', { command: 'pyright.organizeimports', arguments: args });
146
+ });
147
+ // use the file create before
148
+ const modelRef = await createModelReference(monaco.Uri.file('/tmp/hello.py'));
149
+ modelRef.object.setLanguageId(languageId);
150
+ // create monaco editor
151
+ createConfiguredEditor(document.getElementById('container'), {
152
+ model: modelRef.object.textEditorModel,
153
+ automaticLayout: true
154
+ });
155
+ };
156
+ run();
157
+ //# sourceMappingURL=client.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"client.js","sourceRoot":"","sources":["../../src/python/client.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAEhG,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AACjC,OAAO,0CAA0C,CAAC;AAClD,OAAO,kCAAkC,CAAC;AAC1C,OAAO,EAAE,uBAAuB,EA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C,CAAC;AAEF,GAAG,EAAE,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=server.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../src/python/server.ts"],"names":[],"mappings":""}
@@ -0,0 +1,105 @@
1
+ /* --------------------------------------------------------------------------------------------
2
+ * Copyright (c) 2018-2022 TypeFox GmbH (http://www.typefox.io). All rights reserved.
3
+ * Licensed under the MIT License. See License.txt in the project root for license information.
4
+ * ------------------------------------------------------------------------------------------ */
5
+ import { WebSocketServer } from 'ws';
6
+ import { URL } from 'url';
7
+ import express from 'express';
8
+ import { resolve } from 'path';
9
+ import { WebSocketMessageReader, WebSocketMessageWriter } from 'vscode-ws-jsonrpc';
10
+ import { createConnection, createServerProcess, forward } from 'vscode-ws-jsonrpc/server';
11
+ import { Message, InitializeRequest } from 'vscode-languageserver';
12
+ import { getLocalDirectory } from '../utils/fs-utils.js';
13
+ const serverName = 'PYRIGHT';
14
+ const launchLanguageServer = (socket, baseDir, relativeDir) => {
15
+ // start the language server as an external process
16
+ const ls = resolve(baseDir, relativeDir);
17
+ const serverConnection = createServerProcess(serverName, 'node', [ls, '--stdio']);
18
+ const reader = new WebSocketMessageReader(socket);
19
+ const writer = new WebSocketMessageWriter(socket);
20
+ const socketConnection = createConnection(reader, writer, () => socket.dispose());
21
+ if (serverConnection) {
22
+ forward(socketConnection, serverConnection, message => {
23
+ if (Message.isRequest(message)) {
24
+ console.log(`${serverName} Server received:`);
25
+ console.log(message);
26
+ if (message.method === InitializeRequest.type.method) {
27
+ const initializeParams = message.params;
28
+ initializeParams.processId = process.pid;
29
+ }
30
+ }
31
+ if (Message.isResponse(message)) {
32
+ console.log(`${serverName} Server sent:`);
33
+ console.log(message);
34
+ }
35
+ return message;
36
+ });
37
+ }
38
+ };
39
+ const run = () => {
40
+ process.on('uncaughtException', function (err) {
41
+ console.error('Uncaught Exception: ', err.toString());
42
+ if (err.stack) {
43
+ console.error(err.stack);
44
+ }
45
+ });
46
+ // create the express application
47
+ const app = express();
48
+ // server the static content, i.e. index.html
49
+ const dir = getLocalDirectory(import.meta.url);
50
+ app.use(express.static(dir));
51
+ // start the server
52
+ const server = app.listen(30000);
53
+ // create the web socket
54
+ const wss = new WebSocketServer({
55
+ noServer: true,
56
+ perMessageDeflate: false,
57
+ clientTracking: true,
58
+ verifyClient: (clientInfo, callback) => {
59
+ const parsedURL = new URL(`${clientInfo.origin}${clientInfo.req?.url ?? ''}`);
60
+ const authToken = parsedURL.searchParams.get('authorization');
61
+ if (authToken === 'UserAuth') {
62
+ // eslint-disable-next-line n/no-callback-literal
63
+ callback(true);
64
+ }
65
+ else {
66
+ // eslint-disable-next-line n/no-callback-literal
67
+ callback(false);
68
+ }
69
+ }
70
+ });
71
+ server.on('upgrade', (request, socket, head) => {
72
+ const baseURL = `http://${request.headers.host}/`;
73
+ const pathname = request.url ? new URL(request.url, baseURL).pathname : undefined;
74
+ if (pathname === '/pyright') {
75
+ wss.handleUpgrade(request, socket, head, webSocket => {
76
+ const socket = {
77
+ send: content => webSocket.send(content, error => {
78
+ if (error) {
79
+ throw error;
80
+ }
81
+ }),
82
+ onMessage: cb => webSocket.on('message', (data) => {
83
+ cb(data);
84
+ }),
85
+ onError: cb => webSocket.on('error', cb),
86
+ onClose: cb => webSocket.on('close', cb),
87
+ dispose: () => webSocket.close()
88
+ };
89
+ // launch the server when the web socket is opened
90
+ const baseDir = resolve(getLocalDirectory(import.meta.url));
91
+ const relativeDir = '../../../../../node_modules/pyright/dist/pyright-langserver.js';
92
+ if (webSocket.readyState === webSocket.OPEN) {
93
+ launchLanguageServer(socket, baseDir, relativeDir);
94
+ }
95
+ else {
96
+ webSocket.on('open', () => {
97
+ launchLanguageServer(socket, baseDir, relativeDir);
98
+ });
99
+ }
100
+ });
101
+ }
102
+ });
103
+ };
104
+ run();
105
+ //# sourceMappingURL=server.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.js","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IAAI,EAAE,EAAE;wBAC9C,EAAE,CAAC,IAAI,CAAC,CAAC;oBACb,CAAC,CAAC;oBACF,OAAO,EAAE,EAAE,CAAC,EAAE,CAAC,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC;oBACxC,OAAO,EAAE,EAAE,CAAC,EAAE,CAAC,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC;oBACxC,OAAO,EAAE,GAAG,EAAE,CAAC,SAAS,CAAC,KAAK,EAAE;iBACnC,CAAC;gBACF,kDAAkD;gBAClD,MAAM,OAAO,GAAG,OAAO,CAAC,iBAAiB,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;gBAC5D,MAAM,WAAW,GAAG,gEAAgE,CAAC;gBACrF,IAAI,SAAS,CAAC,UAAU,KAAK,SAAS,CAAC,IAAI,EAAE;oBACzC,oBAAoB,CAAC,MAAM,EAAE,OAAO,EAAE,WAAW,CAAC,CAAC;iBACtD;qBAAM;oBACH,SAAS,CAAC,EAAE,CAAC,MAAM,EAAE,GAAG,EAAE;wBACtB,oBAAoB,CAAC,MAAM,EAAE,OAAO,EAAE,WAAW,CAAC,CAAC;oBACvD,CAAC,CAAC,CAAC;iBACN;YACL,CAAC,CAAC,CAAC;SACN;IACL,CAAC,CAAC,CAAC;AACP,CAAC,CAAC;AAEF,GAAG,EAAE,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ export type EditorProps = {
3
+ defaultCode: string;
4
+ hostname: string;
5
+ port: number;
6
+ path: string;
7
+ className?: string;
8
+ };
9
+ export declare const ReactMonacoEditor: React.FC<EditorProps>;
10
+ //# sourceMappingURL=app.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../src/react/app.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAgD,MAAM,OAAO,CAAC;AAOrE,MAAM,MAAM,WAAW,GAAG;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,CAAA;AAED,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,WAAW,CAmDnD,CAAC"}
@@ -0,0 +1,45 @@
1
+ /* --------------------------------------------------------------------------------------------
2
+ * Copyright (c) 2018-2022 TypeFox GmbH (http://www.typefox.io). All rights reserved.
3
+ * Licensed under the MIT License. See License.txt in the project root for license information.
4
+ * ------------------------------------------------------------------------------------------ */
5
+ import { createJsonEditor, createUrl, createWebSocketAndStartClient, performInit } from '../common.js';
6
+ import React, { createRef, useEffect, useMemo, useRef } from 'react';
7
+ import { buildWorkerDefinition } from 'monaco-editor-workers';
8
+ buildWorkerDefinition('../../../node_modules/monaco-editor-workers/dist/workers/', new URL('', window.location.href).href, false);
9
+ let init = true;
10
+ export const ReactMonacoEditor = ({ defaultCode, hostname, path, port, className }) => {
11
+ const editorRef = useRef();
12
+ const ref = createRef();
13
+ const url = useMemo(() => createUrl(hostname, port, path), [hostname, port, path]);
14
+ let lspWebSocket;
15
+ useEffect(() => {
16
+ const currentEditor = editorRef.current;
17
+ if (ref.current != null) {
18
+ const start = async () => {
19
+ await performInit(true);
20
+ await createJsonEditor({
21
+ htmlElement: ref.current,
22
+ content: defaultCode
23
+ });
24
+ if (init) {
25
+ init = false;
26
+ }
27
+ lspWebSocket = createWebSocketAndStartClient(url);
28
+ };
29
+ start();
30
+ return () => {
31
+ currentEditor?.dispose();
32
+ };
33
+ }
34
+ window.onbeforeunload = () => {
35
+ // On page reload/exit, close web socket connection
36
+ lspWebSocket?.close();
37
+ };
38
+ return () => {
39
+ // On component unmount, close web socket connection
40
+ lspWebSocket?.close();
41
+ };
42
+ }, []);
43
+ return (React.createElement("div", { ref: ref, style: { height: '50vh' }, className: className }));
44
+ };
45
+ //# sourceMappingURL=app.js.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,CAAC;gBACH,IAAI,IAAI,EAAE;oBACN,IAAI,GAAG,KAAK,CAAC;iBAChB;gBACD,YAAY,GAAG,6BAA6B,CAAC,GAAG,CAAC,CAAC;YACtD,CAAC,CAAC;YACF,KAAK,EAAE,CAAC;YAER,OAAO,GAAG,EAAE;gBACR,aAAa,EAAE,OAAO,EAAE,CAAC;YAC7B,CAAC,CAAC;SACL;QAED,MAAM,CAAC,cAAc,GAAG,GAAG,EAAE;YACzB,mDAAmD;YACnD,YAAY,EAAE,KAAK,EAAE,CAAC;QAC1B,CAAC,CAAC;QACF,OAAO,GAAG,EAAE;YACR,oDAAoD;YACpD,YAAY,EAAE,KAAK,EAAE,CAAC;QAC1B,CAAC,CAAC;IACN,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,CACH,6BACI,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,EACzB,SAAS,EAAE,SAAS,GACtB,CACL,CAAC;AACN,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=main.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../src/react/main.tsx"],"names":[],"mappings":""}
@@ -0,0 +1,14 @@
1
+ /* --------------------------------------------------------------------------------------------
2
+ * Copyright (c) 2018-2022 TypeFox GmbH (http://www.typefox.io). All rights reserved.
3
+ * Licensed under the MIT License. See License.txt in the project root for license information.
4
+ * ------------------------------------------------------------------------------------------ */
5
+ import React from 'react';
6
+ import ReactDOM from 'react-dom/client';
7
+ import { ReactMonacoEditor } from './app.js';
8
+ const defaultCode = `{
9
+ "$schema": "http://json.schemastore.org/coffeelint",
10
+ "line_endings": "unix"
11
+ }`;
12
+ const root = ReactDOM.createRoot(document.getElementById('root'));
13
+ root.render(React.createElement(ReactMonacoEditor, { defaultCode: defaultCode, hostname: 'localhost', path: '/sampleServer', port: 3000 }));
14
+ //# sourceMappingURL=main.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"main.js","sourceRoot":"","sources":["../../src/react/main.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,QAAQ,MAAM,kBAAkB,CAAC;AACxC,OAAO,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAE7C,MAAM,WAAW,GAAG;;;EAGlB,CAAC;AAEH,MAAM,IAAI,GAAG,QAAQ,CAAC,UAAU,CAAC,QAAQ,CAAC,cAAc,CAAC,MAAM,CAAE,CAAC,CAAC;AACnE,IAAI,CAAC,MAAM,CAAC,oBAAC,iBAAiB,IAC1B,WAAW,EAAE,WAAW,EACxB,QAAQ,EAAE,WAAW,EACrB,IAAI,EAAE,eAAe,EACrB,IAAI,EAAE,IAAI,GAAI,CAAC,CAAC"}
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Solves: __dirname is not defined in ES module scope
3
+ */
4
+ export declare const getLocalDirectory: (referenceUrl: string | URL) => string;
5
+ //# sourceMappingURL=fs-utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fs-utils.d.ts","sourceRoot":"","sources":["../../src/utils/fs-utils.ts"],"names":[],"mappings":"AAOA;;GAEG;AACH,eAAO,MAAM,iBAAiB,iBAAkB,MAAM,GAAG,GAAG,WAG3D,CAAC"}
@@ -0,0 +1,14 @@
1
+ /* --------------------------------------------------------------------------------------------
2
+ * Copyright (c) 2018-2022 TypeFox GmbH (http://www.typefox.io). All rights reserved.
3
+ * Licensed under the MIT License. See License.txt in the project root for license information.
4
+ * ------------------------------------------------------------------------------------------ */
5
+ import { dirname } from 'path';
6
+ import { fileURLToPath } from 'url';
7
+ /**
8
+ * Solves: __dirname is not defined in ES module scope
9
+ */
10
+ export const getLocalDirectory = (referenceUrl) => {
11
+ const __filename = fileURLToPath(referenceUrl);
12
+ return dirname(__filename);
13
+ };
14
+ //# sourceMappingURL=fs-utils.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fs-utils.js","sourceRoot":"","sources":["../../src/utils/fs-utils.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC/B,OAAO,EAAE,aAAa,EAAE,MAAM,KAAK,CAAC;AAEpC;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,YAA0B,EAAE,EAAE;IAC5D,MAAM,UAAU,GAAG,aAAa,CAAC,YAAY,CAAC,CAAC;IAC/C,OAAO,OAAO,CAAC,UAAU,CAAC,CAAC;AAC/B,CAAC,CAAC"}