summaryrefslogtreecommitdiff
path: root/start/lspconfig-0.1.8/lua/lspconfig/server_configurations/rescriptls.lua
diff options
context:
space:
mode:
Diffstat (limited to 'start/lspconfig-0.1.8/lua/lspconfig/server_configurations/rescriptls.lua')
-rw-r--r--start/lspconfig-0.1.8/lua/lspconfig/server_configurations/rescriptls.lua28
1 files changed, 28 insertions, 0 deletions
diff --git a/start/lspconfig-0.1.8/lua/lspconfig/server_configurations/rescriptls.lua b/start/lspconfig-0.1.8/lua/lspconfig/server_configurations/rescriptls.lua
new file mode 100644
index 0000000..882a110
--- /dev/null
+++ b/start/lspconfig-0.1.8/lua/lspconfig/server_configurations/rescriptls.lua
@@ -0,0 +1,28 @@
+local util = require 'lspconfig.util'
+
+return {
+ default_config = {
+ cmd = { 'rescript-language-server', '--stdio' },
+ filetypes = { 'rescript' },
+ root_dir = util.root_pattern('bsconfig.json', 'rescript.json', '.git'),
+ settings = {},
+ init_options = {
+ extensionConfiguration = {
+ askToStartBuild = false,
+ },
+ },
+ },
+ docs = {
+ description = [[
+https://github.com/rescript-lang/rescript-vscode/tree/master/server
+
+ReScript Language Server can be installed via npm:
+```sh
+npm install -g @rescript/language-server
+```
+
+See the init_options supported (see https://github.com/rescript-lang/rescript-vscode/tree/master/server/config.md):
+]],
+ root_dir = [[root_pattern('bsconfig.json', 'rescript.json', '.git')]],
+ },
+}