> For the complete documentation index, see [llms.txt](https://lochiwei.gitbook.io/web/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://lochiwei.gitbook.io/web/js/val/builtin/arr/element.md).

# element

[JS](/web/js.md) ⟩ [object](/web/js/val/obj.md) ⟩ [built-in](/web/js/val/builtin.md) ⟩ [Array](/web/js/val/builtin/arr.md) ⟩ element

{% hint style="success" %}
the [value](/web/js/val.md)(s) stored in the [Array](/web/js/val/builtin/arr.md).
{% endhint %}

{% tabs %}
{% tab title="⭐️ 重點" %}
{% hint style="success" %} <mark style="color:purple;">**array elements**</mark> are usually <mark style="color:yellow;">**accessed**</mark> by [property access expression](/web/js/val/obj/prop/access/property-access-expression.md), <mark style="color:yellow;">**using**</mark> [dot notation (.)](/web/js/val/obj/prop/access/dot-notation-..md) <mark style="color:yellow;">**/**</mark> [bracket notation \[\]](/web/js/val/obj/prop/access/bracket-notation.md).
{% endhint %}

{% hint style="warning" %}
[**deleting**](/web/js/val/obj/prop/create/delete.md) an array <mark style="color:purple;">**element**</mark> leaves a “<mark style="color:yellow;">**hole**</mark>” in the array and <mark style="color:red;">**does not**</mark>**&#x20;**<mark style="color:yellow;">**change**</mark> the array’s <mark style="color:yellow;">**length**</mark>:exclamation: ([sparse array](/web/js/val/builtin/arr/sparse.md))
{% endhint %}
{% endtab %}

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

* :white\_check\_mark: <mark style="color:purple;">**array elements**</mark> are <mark style="color:yellow;">**accessed**</mark> throught [element index](/web/js/val/builtin/arr/element/index.md) using [bracket notation \[\]](/web/js/val/obj/prop/access/bracket-notation.md).
* array <mark style="color:purple;">**element**</mark> is a [lvalue](/web/js/grammar/op/term/lvalue.md).
* [**...iterable**](/web/js/grammar/op/spread.md) <mark style="color:yellow;">**expands**</mark> an [**iterable**](/web/js/iteration/iterable.md) in places where <mark style="color:purple;">**elements**</mark> are expected.&#x20;
  {% endtab %}

{% tab title="📗 參考" %}
\*
{% endtab %}

{% tab title="📘 手冊" %}

* Guides ⟩ Arrays ⟩ [Accessing and modifying array items](https://developer.mozilla.org/en-US/docs/Learn/JavaScript/First_steps/Arrays#accessing_and_modifying_array_items) ⭐️
  {% endtab %}
  {% endtabs %}
