wiki/content/20201014092625-javascript_iterables.md

27 lines
734 B
Markdown
Raw Permalink Normal View History

2024-05-06 20:40:05 +00:00
---
2024-10-30 17:34:11 +00:00
date: 2020-10-14
2024-05-06 20:40:05 +00:00
id: f1c572d5-868b-4ce0-b1ac-9f7cc32dae3d
title: JavaScript Iterables
---
# Introduction
An *iterable* is a data structure that wants to make its elements
accessible to the public. It does so by implementing a method whose key
is
[Symbol.iterator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/iterator).
That method is a factory for
[iterators](20201014092846-javascript_iterator).
# Iterable values
- [Arrays](20200826201029-arrays)
- [Strings](20200922164551-strings)
- [Maps](20201012093745-javascript_maps)
- [Sets](20201012094248-javascript_sets)
- DOM data structures
# See also
- [Destructuring Iterables](20201103112001-destructuring_iterables)