4

Example:

console.log(file)
// File object with properties

const f = {...file}
console.log(f)
// empty Object

file.id = 'abcdef'
const ff = {...file}
console.log(ff)
// Object with only property {id: 'abcdef'}

Anyone can explain or send me a reference link

Patrick Roberts
  • 44,815
  • 8
  • 87
  • 134
Phuc Nguyen
  • 158
  • 2
  • 9

0 Answers0