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

140
Views
how to combine multiple arrays in react and how can we show the map in ascending order

how to merge array of this in react or javascript..can anyone help me with this i want the output something like..all the test array should be in one array...coz i need to find the minimum price and plus i need to show the mapping in ascending order

array :[
    {
    id:0,
    name:'something',
    test: [
          {
           id: 0,
           test_name:'blood',
           price:'200',
           },
            {
            id:1,
           test_name:'kidney',
           price:'300',
           }
         ]
       },
   {      
    id:1,
    name:'something1',
    test: [
          {
           id: 0,
           test_name:'blood2',
           price:'100',
           },
            {
            id:1,
           test_name:'kidney2',
           price:'100',
           }
         ]
       }

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

0

You can use spread operator to merge two array.

var a = [{fname : 'foo'}]
var b = [{lname : 'bar'}]
var c = [...a, ...b] // output is [{fname : 'foo'},{lname : 'bar'}]
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!