Use object spread operator to get remaining values
const props = { width: 10, height: 10, color: 'red' }
const { width, ...rest } = props
// width => 10
// rest => { height: 10, color: 'red' }
Tweet
const props = { width: 10, height: 10, color: 'red' }
const { width, ...rest } = props
// width => 10
// rest => { height: 10, color: 'red' }
Tweet