Custom Components
let’s the user to turn their creativity into action. Components
help users to build exciting features for their projects including styles, features, color-schemes, templates, typography etc.
Components
give scalability, efficiency as well as consistency to the design. Once created can be used and reused as many times throughout the project as well as can be used by others when published on GitHub.
In our Expander project
, we have used the component
and named it as box
. We moved our column code block that represents the box which we created in the last part and re-used the component
three times.
-- component <component-name>: ;; content of component goes here -- end: <component-name>
Component box
is created outside the root column, that represents the box. Then, inside the root column we refer it.-- <component-name>:
-- component <component-name>: caption <caption name>: <default value if any> body <body name>: <default value if any> -- end: <component-name>
-- ftd.text: $box.<caption name> -- ftd.text: $box.<body name>
-- box: Header is in caption area Body is in body area
-- box: title: Header using title keyword Body is in body area
-- box: -- box.title: Header is in first child: box.title. This is used to write multiline header -- box.body: Body is in second child: box.body.
-- box:
fastn
!fastn
? Please consider giving us a star ⭐️ on GitHub to show your support!Have a question or need help?
Visit our GitHub Q&A discussion to get answers and subscribe to it to stay tuned.
Join our Discord channel and share your thoughts, suggestion, question etc.
Connect with our community!We welcome you to join our Discord community today.
We are trying to create the language for human beings and we do not believe it would be possible without your support. We would love to hear from you.