1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-02-03 21:40:05 +08:00
SpaceVim/bundle/nvim-lspconfig/lua/lspconfig/server_configurations/graphql.lua
2024-06-13 08:44:55 +08:00

25 lines
593 B
Lua

local util = require 'lspconfig.util'
return {
default_config = {
cmd = { 'graphql-lsp', 'server', '-m', 'stream' },
filetypes = { 'graphql' },
root_dir = util.root_pattern('.git', '.graphqlrc*', '.graphql.config.*', 'graphql.config.*'),
},
docs = {
description = [[
https://github.com/graphql/graphiql/tree/main/packages/graphql-language-service-cli
`graphql-lsp` can be installed via `npm`:
```sh
npm install -g graphql-language-service-cli
```
]],
default_config = {
root_dir = [[root_pattern('.git', '.graphqlrc*', '.graphql.config.*')]],
},
},
}