> 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/obj-prop.md).

# array object property

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

{% hint style="success" %} <mark style="color:yellow;">**(**</mark>[value](/web/js/val.md)<mark style="color:yellow;">**)**</mark>&#x20;

if you set / access the [Array](/web/js/val/builtin/arr.md) via <mark style="color:yellow;">**anything**</mark>**&#x20;**<mark style="color:red;">**other than**</mark> <mark style="color:blue;">**nonnegative**</mark>**&#x20;**<mark style="color:yellow;">**integers**</mark>, you'll end up setting / accessing one of the array's [object properties](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#properties), which are <mark style="color:yellow;">**stored**</mark>**&#x20;**<mark style="color:red;">**differently**</mark> <mark style="color:yellow;">**from**</mark> the <mark style="color:yellow;">**list**</mark> of [element](/web/js/val/builtin/arr/element.md)(s) :exclamation:
{% endhint %}

{% tabs %}
{% tab title="⭐️ 重點" %}
{% hint style="warning" %}
:scales: **array&#x20;**<mark style="color:yellow;">**object properties**</mark> **vs**. <mark style="color:orange;">**array elements**</mark>&#x20;

* thery are <mark style="color:red;">**separate**</mark>:exclamation:
* array's [traversal and mutation operations](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Indexed_collections#array_methods) <mark style="color:red;">**cannot**</mark>**&#x20;**<mark style="color:yellow;">**be applied**</mark> to these <mark style="color:yellow;">**named properties**</mark>.

setting / accessing via <mark style="color:yellow;">**anything**</mark>**&#x20;**<mark style="color:red;">**other than**</mark> <mark style="color:blue;">**nonnegative**</mark>**&#x20;**<mark style="color:yellow;">**integers**</mark>：

* <mark style="color:yellow;">**will**</mark>**&#x20;**<mark style="color:red;">**not**</mark> set / retrieve an array element
* <mark style="color:green;">**will**</mark> set / access one of the array's [object properties](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#properties).&#x20;
  {% endhint %}
  {% endtab %}

{% tab title="👥 相關" %}
\*
{% endtab %}

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

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

* [ ] [JavaScript data types and data structures](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures) ⟩ [Properties](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Data_structures#properties)
  {% endtab %}
  {% endtabs %}
