Can I use monaco editor with python lsp in pure client without a server #561
Replies: 8 comments 30 replies
-
@liudonghua123 there is this project; https://www.npmjs.com/package/@typefox/pyright-browser |
Beta Was this translation helpful? Give feedback.
-
@kaisalmen Thanks for the recommend pyright-browser |
Beta Was this translation helpful? Give feedback.
-
@kaisalmen Hi, I found the documentation on pyright-browser, TypeFox/pyright is really concise, is there any more detailed documentation or examples I can learn from? |
Beta Was this translation helpful? Give feedback.
-
@msujew is there any further material? ⬆️ |
Beta Was this translation helpful? Give feedback.
-
According to the previous discussion, I implemented code prompts through Worker, but I encountered Safari compatibility problem. |
Beta Was this translation helpful? Give feedback.
-
@msujew Hi, I tried to make a python-browser example using the above-mentioned code. If I put in this repo, it works, see https://github.com/liudonghua123/monaco-languageclient/blob/python-browser-next/packages/examples/src/python/browser/main.ts. If I create a new vite powered project, move related files to created project and start with const workbenchContributionsRegistry = ( Registry.as(Extensions.Workbench));
// workbenchContributionsRegistry is null here
workbenchContributionsRegistry.registerWorkbenchContribution(RegisterConfigurationSchemasContribution, 3 ); The call stack is empty, maybe it comes from I don't know whether it's vite bundler problem or some other configuration problem. Reproduce step:
|
Beta Was this translation helpful? Give feedback.
-
Hi @liudonghua123 with vite dev mode you currently need to be aware of this: It does not apply to a production build as vite is using rollup for that. |
Beta Was this translation helpful? Give feedback.
-
@msujew Hi, Is there any way to remove console.log ? |
Beta Was this translation helpful? Give feedback.
-
Hi, I tried to write a simple demo which use monaco with python lsp support in plain html without server.
I want to use pyodide or pure js to serve as lsp server. Is there any ideas about how to do it?
I found a example monaco-python, but the monaco editor was too old, I try to update monaco editor, then it did not work.
A lot of examples introduced python lsp need to use a server to run lsp server. But I want to make something pure web, maybe use web workers, pyodide and webassembly.
Some reference links.
Beta Was this translation helpful? Give feedback.
All reactions