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

88
Views
Sort object by created date

I have an API which returns the following data and isn't in any order. What would be the best way to do this using the "created" field.

{
  "002": {
    "created": 1651570929442,
    "sub": false,
    "message": "Second Message",
    "user": "Demo"
  },
  "003": {
    "message": "Third Message",
    "created": 1651570933926,
    "user": "Demo",
    "sub": false
  },
  "001": {
    "user": "Demo",
    "created": 1651570928159,
    "sub": false,
    "message": "First Message"
  }
}
{
  Object.entries(data).map(([key, val]) =>
  <div key={key} data-id={key}>
    <div>
      <span>{val.user}</span>:
    </div>
    <div>
      {val.message}
    </div>
  </div>
  )
}
about 4 years ago · Juan Pablo Isaza
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!