summaryrefslogtreecommitdiff
path: root/fnl/config/lsp/settings/jsonls.fnl
diff options
context:
space:
mode:
Diffstat (limited to 'fnl/config/lsp/settings/jsonls.fnl')
-rw-r--r--fnl/config/lsp/settings/jsonls.fnl12
1 files changed, 12 insertions, 0 deletions
diff --git a/fnl/config/lsp/settings/jsonls.fnl b/fnl/config/lsp/settings/jsonls.fnl
new file mode 100644
index 0000000..73e8975
--- /dev/null
+++ b/fnl/config/lsp/settings/jsonls.fnl
@@ -0,0 +1,12 @@
+;; Json schema store catalog language server.
+(module config.lsp.settings.jsonls {autoload {util util}})
+
+(let [schemastore (util.load-plugin :schemastore)]
+ (schemastore.setup {:init_options {:providerFormatter false}
+ :settings {:json {:schemas (schemastore.json.schemas)}}
+ :setup {:commands {:Format [(fn []
+ (vim.lsp.buf.range_formatting []
+ [0
+ 0]
+ [(vim.fn.line "$"
+ 0)]))]}}}))