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

107
Views
Serialize nested and recursive structure into flat one with references

clarification: this is a kind of software identification (and I dont know if it is allowed here)
A time ago I saw an app which has made use of a javascript library for transform nested objects into flat one like this

var a = {
  attr1: "some value",
  attr2: new Date(),
  b: {
    attr1: "some other value",
  }
}
a.b.a = a
transform(a)
/*
[{
  ref: 0,
  attr1: {
    type: "string",
    value: "some value"
  },
  attr2: {
    type: "Date",
    value: "2022-03-09T16:17:03.216Z"
  },
  b: {
    type: "ref",
    value: "1"
  }
 },{
  ref: 1,
  attr1: {
    type: "string",
    value: "some other value"
  },
  b: {
    type: "ref",
    value: "0"
  }
}]
*/

Does anyone know of a library or standard for do that?

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!