nextjs + electronjs
ReferenceError: window is not defined
at file:///C:/Users/User/Desktop/redacted-electron/node_modules/vscode/vscode/src/vs/base/browser/window.js:9:20
at ModuleJob.run (node:internal/modules/esm/module_job:218:25)
at async ModuleLoader.import (node:internal/modules/esm/loader:329:24)
at async importModuleDynamicallyWrapper (node:internal/vm/module:431:15) {
page: '/'
}
import { MonacoEditorReactComp } from '@typefox/monaco-editor-react';
export default function Editor() {
return (
<MonacoEditorReactComp
userConfig={{
wrapperConfig: {
editorAppConfig: {
$type: 'extended',
codeResources: {
main: {
uri: 'a',
text: 'a'
}
}
}
}
}}
style={{
height: '100%'
}}/>
);
}
solved with the following code:
const MonacoEditorReactComp = dynamic(() => import('@typefox/monaco-editor-react').then(mod => mod.MonacoEditorReactComp), { ssr: false });
seems to be connecting to the lsp just fine however cant seem to make it provide anything, its just blank.
seems to be connecting to the lsp just fine however cant seem to make it provide anything, its just blank.
Hi @dxgi do you mean the editor does not contain text or that nothing works (e.g. code completion)?
nothing works, not even code completion even though provided from the language server protocol im using
@dxgi are you sure you are using the correct languageId.
Package @codingame/monaco-vscode-lua-default-extension required for syntax highlighting expects lua as languageId
Not a library issue.