@dkirchhof thanks for your help. Unfortunately the issue is still here after I enabled dynamicRegistration. I still need to restart the LSP to see things changing.
I also noticed that it’s not working well if I don’t start rescript compiler in watch mode rescript -w. It seems that the lsp used the build directory to detect issue rather than the code itself.
the lsp is version 1.66.0…
that’s what I’ve got in my config so far:
rescriptls = {
cmd = {
"node",
"/home/xxx/.local/share/nvim/mason/packages/rescript-language-server/node_modules/@rescript/language-server/out/cli.js",
"--stdio",
},
capabilities = {
workspace = {
didChangeWatchedFiles = {
dynamicRegistration = true,
},
},
},
settings = {
rescript = {
-- codeLens = true,
incrementalTypechecking = {
acrossFiles = true,
enabled = true,
},
-- codeAnalyzer = { enabled = true },
},
},
},