From b514fa638b3df1bbafb908819ef602210efb74eb Mon Sep 17 00:00:00 2001 From: DarkWiiPlayer Date: Wed, 6 Apr 2022 00:36:21 +0200 Subject: [PATCH] Document function arguments --- page/skooma.html | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/page/skooma.html b/page/skooma.html index e03dfe6..889ec55 100644 --- a/page/skooma.html +++ b/page/skooma.html @@ -136,6 +136,22 @@ return document.createElement("my-component") + +

+ Function arguments will be called on the new element.
+ This can be used to easily add custom initialisation logic to elements. +

+

+ + return html.p("Hello", console.log, ", world!") + + + const element = document.createElement("p") + element.innerText = "Hello" + console.log(element) + element.innerText += ", world!" + return element +