From 9c37582f2bcfaf5190eb77784623cd0d4f287e61 Mon Sep 17 00:00:00 2001 From: Fossean1 <53948838+Fossean1@users.noreply.github.com> Date: Mon, 25 Mar 2024 10:59:15 +0500 Subject: [PATCH] Fix init function in 03-styles.md --- docs_md/03-styles.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs_md/03-styles.md b/docs_md/03-styles.md index 4868d1e..278bd92 100644 --- a/docs_md/03-styles.md +++ b/docs_md/03-styles.md @@ -14,7 +14,7 @@ You can pass _nil_ or _empty_table_ to use default values for all components (no local druid = require("druid.druid") local my_style = require("my.amazing.style") -local function init(self) +function init(self) druid.set_default_style(my_style) end ``` @@ -24,7 +24,7 @@ Setup custom style to specific druid instance: local druid = require("druid.druid") local my_style = require("my.amazing.style") -local function init(self) +function init(self) -- This druid instance will be use my_style as default self.druid = druid.new(self, my_style) end @@ -35,7 +35,7 @@ Change component style with _set_style_ function local druid = require("druid.druid") local my_style = require("my.amazing.style") -local function init(self) +function init(self) self.druid = druid.new(self) self.button = self.druid:new_button("node", function() end) -- Setup custom style for specific component