JSFiddle - React, Tailwind, and code Playground

by Alphonsio

HTML

<pre id="output"></pre>

CSS

body {
  background-color: #f0db4f;
}

JavaScript

let arr = [1, 2, 3, 4];

arr.forEach((value, index) => {
  document.getElementById('output').append(index + ' -> ' + value + "\n");
})