I’ve noticed that some neovim configs are separated into several files or folders and the content of each file is wrapped in code like so:
local M = {}
function M.name()
~~~~~~~~
~~~~~~~~
bunch of code
end
return M
I never do this and I’m curious if there’s any advantage to this approach?