Programming With Swift
  • Home
  • About
  • Github
Sign in Subscribe

for-of

A collection of 1 post
How to get the index from for-of loop with JavaScript
How to

How to get the index from for-of loop with JavaScript

In this tutorial I will show you two ways that you can get the index when using a for-of loop. Let's start with the data that I will be using: const shoppingList = [ 'bread', 'milk', 'pie', 'juice' ] Option 1: .keys() The
23 Aug 2021 1 min read
Page 1 of 1
Programming With Swift © 2025
Powered by Ghost