mirror of
https://github.com/Insality/druid.git
synced 2025-09-27 18:12:19 +02:00
Update md docs of custom components
This commit is contained in:
@@ -9,6 +9,7 @@ local SCHEME = {
|
||||
}
|
||||
|
||||
|
||||
-- Component constructor. Template name and nodes are optional. Pass it if you use it in your component
|
||||
function Component:init(template, nodes)
|
||||
self:set_template(template)
|
||||
self:set_nodes(nodes)
|
||||
@@ -19,6 +20,7 @@ function Component:init(template, nodes)
|
||||
end
|
||||
|
||||
|
||||
-- [OPTIONAL] Call on component remove or on druid:final
|
||||
function Component:on_remove()
|
||||
end
|
||||
|
||||
|
@@ -10,7 +10,7 @@ local SCHEME = {
|
||||
}
|
||||
|
||||
|
||||
-- Component constructor
|
||||
-- Component constructor. Template name and nodes are optional. Pass it if you use it in your component
|
||||
function Component:init(template, nodes)
|
||||
-- If your component is gui template, pass the template name and set it
|
||||
self:set_template(template)
|
||||
|
Reference in New Issue
Block a user