Fork me on GitHub
#emacs
<
2022-08-06
>
Drew Verlee04:08:14

Is everyone getting tab completion on all there projects big and small? I assumed my suffering was cljs based, but i'm on a large clojure project now and i can't get edn/* to tab complete anything. files saved, ns loaded. this same thing works fine on a smaller toy project.

Drew Verlee05:08:28

intelliji does give tab completion in the same exact setting.

Drew Verlee05:08:57

edn/* TAB -> edn/read-string edn/read

ag06:08:08

Using clojure-lsp?

Drew Verlee06:08:59

I have it installed yes.

Drew Verlee07:08:39

I'll pay money if someone can help me fix this. I'm beyond frustrated by it.

pesterhazy17:08:47

Might be that clojure-lsp takes a long time to analyze your project

Drew Verlee17:08:10

could be, how would i test that idea? I mean, it never offers the functions no matter how long i wait. This works in emacs on smaller projects though. And it works in calva which i believe uses lsp to get the completion. That's why i'm asking if people are constantly getting this behavior, because i just might want to follow suit rather then try and fix this. Because i'm using stable widely adopted tools and if it's not working i assume it's a very hard problem to solve.

pesterhazy17:08:12

Not gonna lie, I also have problems with lsp in a large project

pesterhazy17:08:58

One thing to try would be to just run the clojure-lsp binary in a terminal in the project root

Drew Verlee20:08:03

If lsp was the bottle neck wouldn't it also not work in vs code then? isn't that what powering the completion there?

Drew Verlee20:08:16

yeah, i'm getting code completion options in vs code without a repl.

Drew Verlee21:08:40

ok, so i get completion (so far) when i narrow the lsp workspace more. Before /.lsp /backend/ /frontend/ Now its /backend/.lsp i really want lsp to span the whole directory. I feel like i have gone through this pain before and the lsp docs will probably have the answer here...

Drew Verlee21:08:43

Additionaly, i might be wrong in my thinking here. I think i was hoping LSP would help me rename keywords across platforms (e.g fe and be) but 1. i can do that with text search replace just as easily. 2. For all other cases it's actually the wrong thing. e.g if i rename the fn foo on the fe i clearly don't necessarily want it renamed on the be. That being said, i'm sure there is a way to share lsp configuration.

Drew Verlee21:08:27

I guess the issue is that text search replace won't help with aliased keywords, but that's a fairly small subset of things...

apt23:08:17

You can also try eglot, for confirming if the issue is in the client or in the server (or neither of them)

👀 1
pesterhazy08:08:14

My problems are related to a monorepo as well

rafalw09:08:44

Hello, for clean es6 development, which mode is the best, javascript-mode, js2-mode, js3-mode, ... ?

pesterhazy17:08:46

I'd like to know as well

David Vujic07:08:44

Not sure if it is the best, but I use a combination of js2-mode, web-mode, json-mode and tide. https://github.com/DavidVujic/my-emacs-config

pppaul20:08:06

i didn't even know there was a js3 mode...