From a5fe8f59d98398d04bed8586cee73864bbcdde92 Mon Sep 17 00:00:00 2001 From: Lewis Russell Date: Tue, 27 Feb 2024 15:20:32 +0000 Subject: docs: improve/add documentation of Lua types - Added `@inlinedoc` so single use Lua types can be inlined into the functions docs. E.g. ```lua --- @class myopts --- @inlinedoc --- --- Documentation for some field --- @field somefield integer --- @param opts myOpts function foo(opts) end ``` Will be rendered as ``` foo(opts) Parameters: - {opts} (table) Object with the fields: - somefield (integer) Documentation for some field ``` - Marked many classes with with `@nodoc` or `(private)`. We can eventually introduce these when we want to. --- runtime/lua/vim/_options.lua | 1 + 1 file changed, 1 insertion(+) (limited to 'runtime/lua/vim/_options.lua') diff --git a/runtime/lua/vim/_options.lua b/runtime/lua/vim/_options.lua index f1fed50c6d..bde9421552 100644 --- a/runtime/lua/vim/_options.lua +++ b/runtime/lua/vim/_options.lua @@ -797,6 +797,7 @@ end --- `vim.opt_global`. --- +--- @nodoc --- @class vim.Option local Option = {} -- luacheck: no unused -- cgit