update README.md

neovim_0.6
ray-x 3 years ago
parent 427007ee9b
commit 4c7e7f683d

@ -607,14 +607,14 @@ require'navigator'.setup({
``` ```
```lua ```lua
-- output the logs
local log = require"navigator.util".log -- a example of adding logs in the plugin
-- output your log local log = require"navigator.util".log
local definition_hdlr = util.mk_handler(function(err, locations, ctx, _) local definition_hdlr = util.mk_handler(function(err, locations, ctx, _)
log('this is a log for locations', locations, "and ctx", ctx) -- output your log
log('[definition] log for locations', locations, "and ctx", ctx)
if err ~= nil then if err ~= nil then
return return
end end

Loading…
Cancel
Save