# nested function

[JS](https://lochiwei.gitbook.io/web/js) ⟩ [value](https://lochiwei.gitbook.io/web/js/val) ⟩ [function](https://lochiwei.gitbook.io/web/js/val/func) ⟩ nested function

{% hint style="success" %}
a [..](https://lochiwei.gitbook.io/web/js/val/func "mention") is called "<mark style="color:purple;">**nested**</mark>" when it is created <mark style="color:yellow;">**inside**</mark> another function.
{% endhint %}

{% tabs %}
{% tab title="👥 相關" %}

* a [closure](https://lochiwei.gitbook.io/web/js/val/func/closure "mention") is usually a [nested](https://lochiwei.gitbook.io/web/js/val/func/kind/nested "mention").
  {% endtab %}

{% tab title="📗 參考" %}

* [ ] JS.info ⟩ [Nested functions](https://javascript.info/closure#nested-functions)
  {% endtab %}
  {% endtabs %}
