What is the most efficient way to call a Neovim function using Lua. I am able to call the sign_define
Vim script function using the nvim_command
procedure. I struggle with calling it with the nvim_call_function
due to (assuming) converting the lua table to a Vim script dict.
-- Change default signcolumn signs for LSP
api.nvim_call_function('sign_define', {"LspDiagnosticsErrorSign", '{"text" : "", "texthl" : "LspDiagnosticsError"}'})
api.nvim_command('call sign_define("LspDiagnosticsWarningSign", {"text" : "", "texthl" : "LspDiagnosticsWarning"})')
Separately, I wonder if there may be errors due to lua's lack of Unicode support (stdlib).