WindUI

Configs

Creating Configs. Saving and Loading it

Load ConfigManager

local ConfigManager = Window.ConfigManager

Create Config File

local myConfig = ConfigManager:CreateConfig("myConfigExample")

Register elements

myConfig:Register("SpecialNameExample", Element)

Example Register

local ToggleElement = Tabs.ConfigTab:Toggle({
    Title = "Toggle",
    Desc = "Config Test Toggle",
    Callback = function(v) print("Toggle Changed: " .. tostring(v)) end
})
 
-- register
--                 | Element name (no spaces)    | Element          |
myConfig:Register( "toggleNameExample",          ToggleElement      )

Save & Load configs

The config will be saved in

myConfigExample.json

Save

myConfig:Save()

Load

myConfig:Load()

On this page