3 files changed,
8 insertions(+),
8 deletions(-)
Author:
Oleksandr Smirnov
olexsmir@gmail.com
Committed at:
2025-09-12 20:25:09 +0300
Change ID:
mwwzlnvmxskznqnwzwnsvxqnknpqromv
Parent:
7c198a1
M
doc/gopher.nvim.txt
@@ -45,12 +45,6 @@
============================================================================== ------------------------------------------------------------------------------ - *config* - `config` -Type ~ -`(gopher.Config)` - ------------------------------------------------------------------------------- *gopher.nvim-config* `default_config` >lua
M
lua/gopher/config.lua
@@ -1,3 +1,6 @@
+---@type gopher.Config +---@dochide +---@diagnostic disable-next-line: missing-fields .setup() gets injected later local config = {} ---@tag gopher.nvim-config.ConfigGoTagTransform@@ -16,6 +19,7 @@ ---@toc_entry Config
---@tag gopher.nvim-config ---@eval return MiniDoc.afterlines_to_code(MiniDoc.current.eval_section) ---@class gopher.Config +---@field setup fun(user_config?: gopher.Config) local default_config = { -- log level, you might consider using DEBUG or TRACE for debugging the plugin ---@type number@@ -112,5 +116,4 @@ end,
}) ---@dochide ----@return gopher.Config -return config --[[ @as gopher.Config ]] +return config
M
spec/unit/config_test.lua
@@ -7,11 +7,14 @@ require("gopher").setup()
end config["can be called with empty table"] = function() + ---@diagnostic disable-next-line: missing-fields require("gopher").setup {} end config["should change option"] = function() local log_level = 1234567890 + + ---@diagnostic disable-next-line: missing-fields require("gopher").setup { log_level = log_level, }