I am seeking advice on whether it is feasible and the process to follow for storing an image in an array. As someone who is new to JavaScript, I would greatly appreciate a detailed explanation of how this can be achieved along with the syntax involved. My attempts have included using locally stored images as well as URLs from the internet. The goal is to showcase these images when specific conditions are met and a button is clicked. Specifically, I am working on developing a movie suggestion website that will exhibit an array of images upon selecting a genre and clicking the button. While I acknowledge that my code is far from complete, any guidance in the right direction would be invaluable.
My attempt at storing images in an array is reflected below, albeit without success
var images = ['github-logo.png', 'linkedin-logo.png', 'gmail.png']