{% assign sig = include.value.signatures[0] %}

Signature

{% assign num_parameters = sig.parameters | size %} {% if num_parameters == 0 %} {% else %} {%- for param in sig.parameters -%} {% if forloop.first %} {% else %} {% endif %} {%- endfor -%} {% endif %}
function {{ sig.name }} {{- "(" -}} {{- "): " -}} {% include api_helper_type.html type=sig.type %};
function {{ sig.name }} {{- "(" -}}   {{- param.name -}} {%- if param.defaultValue -%} ?: {%- else -%} : {% endif %} {% include api_helper_type.html type=param.type %} {%- if forloop.last -%} {{- "): " -}} {% include api_helper_type.html type=sig.type %}; {% else %} {{- "," -}} {% endif %}