init.lua/lua/lsp/providers/jsonls.lua(view raw)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
return {
settings = {
schemas = {
{ fileMatch = { "package.json" }, url = "https://json.schemastore.org/package.json" },
},
},
}
--[[
return {
settings = {
json = {
schemas = {
{
description = "TypeScript compiler configuration file",
url = "https://json.schemastore.org/tsconfig.json",
fileMatch = { "tsconfig.json", "tsconfig.*.json" },
},
{
description = "Lerna config",
url = "https://json.schemastore.org/lerna.json",
fileMatch = { "lerna.json" },
},
{
description = "ESLint config",
url = "https://json.schemastore.org/eslintrc.json",
fileMatch = { ".eslintrc.json", ".eslintrc" },
},
{
description = "Prettier config",
url = "https://json.schemastore.org/prettierrc",
fileMatch = { ".prettierrc", ".prettierrc.json", "prettier.config.json" },
},
{
description = "golangci-lint configuration file",
fileMatch = { ".golangci.toml", ".golangci.json" },
url = "https://json.schemastore.org/golangci-lint.json",
},
{
description = "NPM configuration file",
fileMatch = { "package.json" },
url = "https://json.schemastore.org/package.json",
},
},
},
},
}]]
|