I'm currently trying to set up Grammarly for nvim, I'd like to login and use the autocompletion Grammarly suggests.
This is what I currently have, besides the normal lsp configurations.
require'lspconfig'.grammarly.setup{
cmd = { "unofficial-grammarly-language-server", "--stdio" },
filetypes = { "markdown" , "tex" },
handlers = {["$/updateDocumentState"] = <function 1> },
grammarly = { 'login' },
}
Ideally I would trigger the changes with the code_action function, right?
vim.api.nvim_buf_set_keymap(bufnr, "n", "ga", "lua vim.lsp.buf.code_action()", opts)
Could you kindly guide me to solve those two task?
Thank you!