I am trying to give image name in src dynamically. I want to set image name dynamically using variable with path. but I am not able to set src correctly. I tried solutions o
Dynamic require doesn't seems to be clean and also eslint isn't happy with it (not sure why)
Other two approaches if images are stored in public folder :
const imgNameWithPath = '/fullImageNameWithPath.jpg'
Using env
Using location origin: