diff --git a/README.md b/README.md index 9b2fc1d..153a6a3 100644 --- a/README.md +++ b/README.md @@ -394,6 +394,7 @@ Writing `print(vim.inspect(x))` every time you want to inspect the contents of a function _G.dump(...) local objects = vim.tbl_map(vim.inspect, {...}) print(unpack(objects)) + return ... end ``` diff --git a/doc/nvim-lua-guide.txt b/doc/nvim-lua-guide.txt index f682d5b..ff4101a 100644 --- a/doc/nvim-lua-guide.txt +++ b/doc/nvim-lua-guide.txt @@ -488,6 +488,7 @@ have a global wrapper function somewhere in your configuration: function _G.dump(...) local objects = vim.tbl_map(vim.inspect, {...}) print(unpack(objects)) + return ... end <