Im new to react
I created my react project using create-react-app.
I need the same functionality as import logo from './logo.png';but for a directory.
something like import * as Images from './images/'; and Images would be an array.
I found some solutions for webpack but they obviously don't work, is this possible in my situation?
for context here is how i want to use the images. Currently, they are hardcoded into this.state.images[]
const style = {
//overflowY: "scroll",
height: 5000,
width: "100%",
backgroudImage: `url(${this.state.images[this.state.index]})`,
backgroundPosition: "center",
backgroundSize: "cover",
backgroundRepeat: "no-repeat"
};
Thank you in advance.