Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

235
Views
how to render array of only urls in react js?

I am making a web app which is getting data in the form of http url which are of images eg:

let array = ["https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m000.jpgtoken=e7bf6b3b8fa25c218502b913a9c722ec374229d6&ttl=1633968000","https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m001.jpg?token=3cd1bb77873151a1311e0f87d3cdd68100045326&ttl=1633968000",     "https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m002.jpg?token=74b31d27c19d32b1abb3db47eeb97a5cb4f381c7&ttl=1633968000","https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m003.jpg?token=ff06277b89a5764deccae021411342de9947f130&ttl=1633968000","https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m004.jpg?token=a5641dc8ed4d61de17793f94a45e69ab38f5fce3&ttl=1633968000","https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m005.jpg?token=659f9f64adad8356006bc939365b492004bedc12&ttl=1633968000","https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m006.jpg?token=46641b886d2eef796860c5d29e2959e4cb621945&ttl=1633968000","https://zjcdn.mangafox.me/store/manga/31721/142.0/compressed/m007.jpg?token=6c8ff51fd06f5a0171bde3e3bee2c68606985918&ttl=1633968000"]

and I want to render them on page I have used following code:

`{ 
       arr.map(e=>{
           return <img src={`${e}`} alt="" />  
       })
         
       } `

and this:

arr.map(e=> (<img src={e} alt="" />))

but the problem is it is only rendering one image instead of rendering all images.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

I think you have got some issues with your array as it would appear is has some format problems. Here is the fix

{
array.map((el,i )=> <img key={i} src={el} /> )
}
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!