Just putting another option here.
loc_array.splice(-1)[0] === 'index.html' I found the above approach more clean and short onliner. Please, free feel to try this one.
Just putting another option here.
loc_array.splice(-1)[0] === 'index.html' I found the above approach more clean and short onliner. Please, free feel to try this one.