Widgets are reusable jinja templates which can be used in other
themplates. Widgets are written in widgets/ directory in every frappe
module and can be accessed as `{{ widgets.WidgetName(...) }}` from any
template.
15 lines
266 B
HTML
15 lines
266 B
HTML
{#
|
|
Widget to demonostrate how to write a widget.
|
|
|
|
A wiget is a reusable template, that can be used in
|
|
other templates.
|
|
|
|
To this widget can be called as:
|
|
|
|
{{ widgets.HelloWorld(name="World") }}
|
|
#}
|
|
|
|
<div class="hello">
|
|
Hello, <em>{{ name }}</em>!
|
|
</div>
|