Obtenha o último item na JS Array

const lastItem = colors[colors.length - 1]
Xenophobic Xenomorph